Class GcpLoginCallbackHandler
java.lang.Object
com.google.cloud.hosted.kafka.auth.GcpLoginCallbackHandler
- All Implemented Interfaces:
CallbackHandler,org.apache.kafka.common.security.auth.AuthenticateCallbackHandler
public class GcpLoginCallbackHandler
extends Object
implements org.apache.kafka.common.security.auth.AuthenticateCallbackHandler
A callback handler that provides a Google OAuth token to a Kafka client.
This callback handler is used by the Kafka client to authenticate to a Google's Kafka server using OAuth.
-
Constructor Summary
ConstructorsConstructorDescriptionCreates a new callback handler using the default application credentials. -
Method Summary
-
Constructor Details
-
GcpLoginCallbackHandler
public GcpLoginCallbackHandler()Creates a new callback handler using the default application credentials.
-
-
Method Details
-
configure
public void configure(Map<String, ?> configs, String saslMechanism, List<AppConfigurationEntry> jaasConfigEntries) - Specified by:
configurein interfaceorg.apache.kafka.common.security.auth.AuthenticateCallbackHandler
-
handle
- Specified by:
handlein interfaceCallbackHandler- Throws:
UnsupportedCallbackExceptionIOException
-
close
public void close()- Specified by:
closein interfaceorg.apache.kafka.common.security.auth.AuthenticateCallbackHandler
-