public class InstanceProfileCredentialsProvider extends Object implements AWSCredentialsProvider
Modifier and Type | Field and Description |
---|---|
protected AWSCredentials |
credentials
The current instance profile credentials
|
protected Date |
credentialsExpiration
The expiration for the current instance profile credentials
|
protected Date |
lastInstanceProfileCheck
The time of the last attempt to check for new credentials
|
Constructor and Description |
---|
InstanceProfileCredentialsProvider() |
Modifier and Type | Method and Description |
---|---|
AWSCredentials |
getCredentials()
Returns AWSCredentials which the caller can use to authorize an AWS request.
|
protected boolean |
needsToLoadCredentials() |
void |
refresh()
Forces this credentials provider to refresh its credentials.
|
String |
toString() |
protected volatile AWSCredentials credentials
protected volatile Date credentialsExpiration
protected volatile Date lastInstanceProfileCheck
public AWSCredentials getCredentials()
AWSCredentialsProvider
getCredentials
in interface AWSCredentialsProvider
public void refresh()
AWSCredentialsProvider
refresh
in interface AWSCredentialsProvider
protected boolean needsToLoadCredentials()
Copyright © 2014. All rights reserved.