Class: Ksql::Connection::Client
- Inherits:
-
Object
- Object
- Ksql::Connection::Client
- Defined in:
- lib/ksql/connection/client.rb
Class Method Summary collapse
-
.call_async(request) ⇒ Array
Prepare the HTTP2 Async Request based on the built input request.
-
.call_sync(request) ⇒ Ksql::Connection::Response
Execute the HTTP2 Sync Request.
Class Method Details
.call_async(request) ⇒ Array
Prepare the HTTP2 Async Request based on the built input request
28 29 30 31 32 |
# File 'lib/ksql/connection/client.rb', line 28 def call_async(request) @@client = client prepared_request = @@client.prepare_request(*request.to_params) return @@client, prepared_request end |
.call_sync(request) ⇒ Ksql::Connection::Response
Execute the HTTP2 Sync Request
16 17 18 19 |
# File 'lib/ksql/connection/client.rb', line 16 def call_sync(request) response = client.call(*request.to_params) ::Ksql::Connection::Response.new(body: response.body, headers: response.headers) end |