Top Description Methods
com.oracle.bmc.auth

public Interface ProvidesConfigurableRefresh

Known Direct Implementers
com.oracle.bmc.auth.internal.AbstractFederationClient, com.oracle.bmc.auth.internal.FileBasedResourcePrincipalFederationClient, com.oracle.bmc.auth.internal.FixedContentResourcePrincipalFederationClient, com.oracle.bmc.auth.internal.X509FederationClient
Imports
java.time.Duration

An interface that has the API to return refresh security token after if the token expires within a configurable time

Method Summary

Modifier and TypeMethod and Description
public String

Returns:

A security token that can be used to authenticate requests.
refreshAndGetSecurityTokenIfExpiringWithin
(Duration
the duration to check
time
)

Gets a security token from the federation endpoint if the security token expires within the provided duration.

public String

Returns:

A security token that can be used to authenticate requests.
refreshAndGetSecurityTokenIfExpiringWithin
(Duration
the duration to check
time
,
boolean
boolean value to enable/disable refresh of keys
refreshKeys
)

Gets a security token from the federation endpoint if the security token expires within the provided duration and allows to enable/disable refresh of keys.

Method Detail

refreshAndGetSecurityTokenIfExpiringWithinback to summary
public String refreshAndGetSecurityTokenIfExpiringWithin(Duration time)

Gets a security token from the federation endpoint if the security token expires within the provided duration. This will always retrieve a new token from the federation endpoint and does not use a cached token.

Parameters
time:Duration

the duration to check

Returns:String

A security token that can be used to authenticate requests.

refreshAndGetSecurityTokenIfExpiringWithinback to summary
public String refreshAndGetSecurityTokenIfExpiringWithin(Duration time, boolean refreshKeys)

Gets a security token from the federation endpoint if the security token expires within the provided duration and allows to enable/disable refresh of keys. This will always retrieve a new token from the federation endpoint and does not use a cached token.

Parameters
time:Duration

the duration to check

refreshKeys:boolean

boolean value to enable/disable refresh of keys

Returns:String

A security token that can be used to authenticate requests.