Package com.databricks.sdk.core.oauth
Class SessionCredentials
- java.lang.Object
-
- com.databricks.sdk.core.oauth.RefreshableTokenSource
-
- com.databricks.sdk.core.oauth.SessionCredentials
-
- All Implemented Interfaces:
CredentialsProvider
,TokenSource
,Serializable
public class SessionCredentials extends RefreshableTokenSource implements CredentialsProvider, Serializable
An implementation of RefreshableTokenSource implementing the refresh_token OAuth grant type.SessionCredentials are OAuth credentials with a short-lived access token, used to make requests to an API, and a long-lived refresh token, which can be used to fetch new access tokens. Calling refresh() uses the refresh token to retrieve a new access token to authenticate to APIs.
- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from class com.databricks.sdk.core.oauth.RefreshableTokenSource
token
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
authType()
HeaderFactory
configure(DatabricksConfig config)
protected Token
refresh()
-
Methods inherited from class com.databricks.sdk.core.oauth.RefreshableTokenSource
getToken, retrieveToken
-
-
-
-
Method Detail
-
authType
public String authType()
- Specified by:
authType
in interfaceCredentialsProvider
-
configure
public HeaderFactory configure(DatabricksConfig config)
- Specified by:
configure
in interfaceCredentialsProvider
-
refresh
protected Token refresh()
- Specified by:
refresh
in classRefreshableTokenSource
-
-