java.io.Closeable, java.lang.AutoCloseable, BoundDTExtensionpublic final class CustomTokenProviderAdapter extends AccessTokenProvider implements BoundDTExtension
| Constructor | Description |
|---|---|
CustomTokenProviderAdapter(CustomTokenProviderAdaptee adaptee,
int customTokenFetchRetryCount) |
Constructs a token provider based on the custom token provider.
|
| Modifier and Type | Method | Description |
|---|---|---|
void |
bind(java.net.URI fsURI,
org.apache.hadoop.conf.Configuration conf) |
Bind to the filesystem by passing the binding call on
to any custom token provider adaptee which implements
BoundDTExtension. |
void |
close() |
|
protected CustomTokenProviderAdaptee |
getCustomTokenProviderAdaptee() |
|
java.lang.String |
getUserAgentSuffix() |
Get a suffix for the UserAgent suffix of HTTP requests, which
can be used to identify the principal making ABFS requests.
|
protected AzureADToken |
refreshToken() |
the method to fetch the access token.
|
getToken, isTokenAboutToExpireclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetCanonicalServiceNamepublic CustomTokenProviderAdapter(CustomTokenProviderAdaptee adaptee, int customTokenFetchRetryCount)
adaptee - the custom token providercustomTokenFetchRetryCount - max retry count for customTokenFetchprotected AzureADToken refreshToken() throws java.io.IOException
AccessTokenProviderrefreshToken in class AccessTokenProviderAzureADToken containing the access tokenjava.io.IOException - if there is an error fetching the tokenpublic void bind(java.net.URI fsURI,
org.apache.hadoop.conf.Configuration conf)
throws java.io.IOException
BoundDTExtension.
No-op if they don't.bind in interface BoundDTExtensionfsURI - URI of the filesystem.conf - configuration of this extension.java.io.IOException - failure.public void close()
close in interface java.lang.AutoCloseableclose in interface java.io.Closeablepublic java.lang.String getUserAgentSuffix()
getUserAgentSuffix in interface BoundDTExtension@VisibleForTesting protected CustomTokenProviderAdaptee getCustomTokenProviderAdaptee()
Copyright © 2008–2025 Apache Software Foundation. All rights reserved.