class Kafka::Protocol::SaslHandshakeRequest
SaslHandshake Request (Version: 0) => mechanism
mechanism => string
Constants
- SUPPORTED_MECHANISMS
Public Class Methods
new(mechanism)
click to toggle source
# File lib/kafka/protocol/sasl_handshake_request.rb, line 13 def initialize(mechanism) unless SUPPORTED_MECHANISMS.include?(mechanism) raise Kafka::Error, "Unsupported SASL mechanism #{mechanism}. Supported are #{SUPPORTED_MECHANISMS.join(', ')}" end @mechanism = mechanism end
Public Instance Methods
api_key()
click to toggle source
# File lib/kafka/protocol/sasl_handshake_request.rb, line 20 def api_key SASL_HANDSHAKE_API end
encode(encoder)
click to toggle source
# File lib/kafka/protocol/sasl_handshake_request.rb, line 28 def encode(encoder) encoder.write_string(@mechanism) end
response_class()
click to toggle source
# File lib/kafka/protocol/sasl_handshake_request.rb, line 24 def response_class SaslHandshakeResponse end