@ConfigurationProperties(value="client-credentials") public static class OauthClientConfigurationProperties.ClientCredentialsConfigurationProperties extends AbstractOutgoingRequestProcessorMatcher implements ClientCredentialsConfiguration
Modifier and Type | Class and Description |
---|---|
static class |
OauthClientConfigurationProperties.ClientCredentialsConfigurationProperties.HeaderTokenPropagatorConfigurationProperties
Client credentials http header token propagation configuration.
|
Modifier and Type | Field and Description |
---|---|
static boolean |
DEFAULT_ENABLED
The default enable value.
|
serviceIdPattern, serviceIdRegex, uriPattern, uriRegex
Constructor and Description |
---|
ClientCredentialsConfigurationProperties() |
Modifier and Type | Method and Description |
---|---|
java.util.Map<java.lang.String,java.lang.String> |
getAdditionalRequestParams() |
java.time.Duration |
getAdvancedExpiration() |
java.util.Optional<ClientCredentialsHeaderTokenPropagatorConfiguration> |
getHeaderPropagation() |
java.util.Optional<java.lang.String> |
getScope() |
boolean |
isEnabled() |
void |
setAdditionalRequestParams(java.util.Map<java.lang.String,java.lang.String> additionalRequestParams)
Additional parameters included in the client-credentials flow.
|
void |
setAdvancedExpiration(java.time.Duration advancedExpiration) |
void |
setEnabled(boolean enabled)
Enables
ClientCredentialsClient . |
void |
setHeaderPropagation(OauthClientConfigurationProperties.ClientCredentialsConfigurationProperties.HeaderTokenPropagatorConfigurationProperties headerPropagation)
Sets the Http Header Client Credentials Token Propagator configuration.
|
void |
setScope(java.lang.String scope)
Scope to be requested in the client credentials request.
|
getServiceIdPattern, getServiceIdRegex, getUriPattern, getUriRegex, setServiceIdRegex, setUriRegex
public static final boolean DEFAULT_ENABLED
public ClientCredentialsConfigurationProperties()
@NonNull public java.time.Duration getAdvancedExpiration()
getAdvancedExpiration
in interface ClientCredentialsConfiguration
@NonNull public java.util.Optional<ClientCredentialsHeaderTokenPropagatorConfiguration> getHeaderPropagation()
getHeaderPropagation
in interface ClientCredentialsConfiguration
public void setHeaderPropagation(@NonNull OauthClientConfigurationProperties.ClientCredentialsConfigurationProperties.HeaderTokenPropagatorConfigurationProperties headerPropagation)
headerPropagation
- client credentials header propagation.public void setAdvancedExpiration(@NonNull java.time.Duration advancedExpiration)
advancedExpiration
- Number of seconds for a token obtained via client credentials grant to be considered expired
prior to its expiration date. Default value (30 seconds).@NonNull public java.util.Optional<java.lang.String> getScope()
getScope
in interface ClientCredentialsConfiguration
public void setScope(java.lang.String scope)
scope
- Scope to be requested in the client credentials requestpublic boolean isEnabled()
isEnabled
in interface io.micronaut.core.util.Toggleable
public void setEnabled(boolean enabled)
ClientCredentialsClient
. Default value trueenabled
- enabled flag@NonNull public java.util.Map<java.lang.String,java.lang.String> getAdditionalRequestParams()
getAdditionalRequestParams
in interface ClientCredentialsConfiguration
public void setAdditionalRequestParams(@MapFormat(transformation=FLAT) java.util.Map<java.lang.String,java.lang.String> additionalRequestParams)
additionalRequestParams
- Map of additional request parameters to include in client-credentials flow