From 6b801a8d2e3ec387c681100df02de49b322ffedd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lars=20J=C3=B8rgen=20Solberg?= Date: Mon, 25 Jul 2016 08:40:38 +0000 Subject: implement sasl PLAIN mechanism --- kafka/errors.py | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) (limited to 'kafka/errors.py') diff --git a/kafka/errors.py b/kafka/errors.py index c005bf8..069c9e4 100644 --- a/kafka/errors.py +++ b/kafka/errors.py @@ -58,6 +58,14 @@ class CommitFailedError(KafkaError): pass +class AuthenticationMethodNotSupported(KafkaError): + pass + + +class AuthenticationFailedError(KafkaError): + retriable = False + + class BrokerResponseError(KafkaError): errno = None message = None @@ -328,6 +336,18 @@ class InvalidTimestampError(BrokerResponseError): description = ('The timestamp of the message is out of acceptable range.') +class UnsupportedSaslMechanismError(BrokerResponseError): + errno = 33 + message = 'UNSUPPORTED_SASL_MECHANISM' + description = ('The broker does not support the requested SASL mechanism.') + + +class IllegalSaslStateError(BrokerResponseError): + errno = 34 + message = 'ILLEGAL_SASL_STATE' + description = ('Request is not valid given the current SASL state.') + + class KafkaUnavailableError(KafkaError): pass -- cgit v1.2.1