Class: Kafka::Protocol::HeartbeatRequest
- Inherits:
-
Object
- Object
- Kafka::Protocol::HeartbeatRequest
- Defined in:
- lib/kafka/protocol/heartbeat_request.rb
Instance Method Summary collapse
- #api_key ⇒ Object
- #encode(encoder) ⇒ Object
-
#initialize(group_id:, generation_id:, member_id:) ⇒ HeartbeatRequest
constructor
A new instance of HeartbeatRequest.
- #response_class ⇒ Object
Constructor Details
#initialize(group_id:, generation_id:, member_id:) ⇒ HeartbeatRequest
Returns a new instance of HeartbeatRequest.
6 7 8 9 10 |
# File 'lib/kafka/protocol/heartbeat_request.rb', line 6 def initialize(group_id:, generation_id:, member_id:) @group_id = group_id @generation_id = generation_id @member_id = member_id end |
Instance Method Details
#api_key ⇒ Object
12 13 14 |
# File 'lib/kafka/protocol/heartbeat_request.rb', line 12 def api_key HEARTBEAT_API end |
#encode(encoder) ⇒ Object
20 21 22 23 24 |
# File 'lib/kafka/protocol/heartbeat_request.rb', line 20 def encode(encoder) encoder.write_string(@group_id) encoder.write_int32(@generation_id) encoder.write_string(@member_id) end |
#response_class ⇒ Object
16 17 18 |
# File 'lib/kafka/protocol/heartbeat_request.rb', line 16 def response_class HeartbeatResponse end |