Package org.apache.gravitino.credential
Interface CredentialProvider
- All Superinterfaces:
AutoCloseable
,Closeable
Interface for credential providers.
A credential provider is responsible for managing and retrieving credentials.
-
Method Summary
Modifier and TypeMethodDescriptionReturns the type of credential, it should be identical in Gravitino.getCredential
(CredentialContext context) Obtains a credential based on the provided context information.void
initialize
(Map<String, String> properties) Initializes the credential provider with catalog properties.
-
Method Details
-
initialize
Initializes the credential provider with catalog properties.- Parameters:
properties
- catalog properties that can be used to configure the provider. The specific properties required vary by implementation.
-
credentialType
String credentialType()Returns the type of credential, it should be identical in Gravitino.- Returns:
- A string identifying the type of credentials.
-
getCredential
Obtains a credential based on the provided context information.- Parameters:
context
- A context object providing necessary information for retrieving credentials.- Returns:
- A Credential object containing the authentication information needed to access a system or resource. Null will be returned if no credential is available.
-