Class OciConfig.BuilderBase<BUILDER extends OciConfig.BuilderBase<BUILDER,PROTOTYPE>,PROTOTYPE extends OciConfig>
- Type Parameters:
BUILDER
- type of the builder extending this abstract builderPROTOTYPE
- type of the prototype interface
- Direct Known Subclasses:
OciConfig.Builder
- Enclosing interface:
- OciConfig
OciConfig
.-
Nested Class Summary
Modifier and TypeClassDescriptionprotected static class
Generated implementation of the prototype, can be extended by descendant prototype implementations. -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionaddAuthStrategies
(List<? extends String> authStrategies) The list of authentication strategies that will be attempted byAbstractAuthenticationDetailsProvider
when one is called for.The OCI authentication fingerprint.authFingerprint
(String authFingerprint) The OCI authentication fingerprint.The OCI authentication key file.authKeyFile
(String authKeyFile) The OCI authentication key file.Optional<char[]>
The OCI authentication passphrase.authPassphrase
(char[] authPassphrase) The OCI authentication passphrase.authPassphrase
(String authPassphrase) The OCI authentication passphrase.Optional<char[]>
The OCI authentication private key.authPrivateKey
(char[] authPrivateKey) The OCI authentication private key.authPrivateKey
(String authPrivateKey) The OCI authentication private key.The OCI authentication key file path.authPrivateKeyPath
(String authPrivateKeyPath) The OCI authentication key file path.The OCI region.authRegion
(String authRegion) The OCI region.The list of authentication strategies that will be attempted byAbstractAuthenticationDetailsProvider
when one is called for.authStrategies
(List<? extends String> authStrategies) The list of authentication strategies that will be attempted byAbstractAuthenticationDetailsProvider
when one is called for.The singular authentication strategy to apply.authStrategy
(String authStrategy) The singular authentication strategy to apply.The OCI tenant id.authTenantId
(String authTenantId) The OCI tenant id.The OCI user id.authUserId
(String authUserId) The OCI user id.Clear existing value of this property.Clear existing value of this property.Clear existing value of this property.Clear existing value of this property.Clear existing value of this property.Clear existing value of this property.Clear existing value of this property.Clear existing value of this property.Clear existing value of this property.Clear existing value of this property.config()
If this instance was configured, this would be the config instance used.Update builder from configuration (node of this type).The OCI configuration profile path.configPath
(String configPath) The OCI configuration profile path.The OCI configuration/auth profile name.configProfile
(String configProfile) The OCI configuration/auth profile name.Update this builder from an existing prototype instance.from
(OciConfig.BuilderBase<?, ?> builder) Update this builder from an existing prototype builder instance.The OCI IMDS hostname.imdsHostName
(String imdsHostName) The OCI IMDS hostname.The OCI IMDS connection timeout.imdsTimeout
(Duration imdsTimeout) The OCI IMDS connection timeout.protected void
Handles providers and decorators.toString()
protected void
Validates required properties.
-
Constructor Details
-
BuilderBase
protected BuilderBase()Protected to support extensibility.
-
-
Method Details
-
from
Update this builder from an existing prototype instance.- Parameters:
prototype
- existing prototype to update this builder from- Returns:
- updated builder instance
-
from
Update this builder from an existing prototype builder instance.- Parameters:
builder
- existing builder prototype to update this builder from- Returns:
- updated builder instance
-
preBuildPrototype
protected void preBuildPrototype()Handles providers and decorators. -
validatePrototype
protected void validatePrototype()Validates required properties. -
config
Update builder from configuration (node of this type). If a value is present in configuration, it would override currently configured values.- Parameters:
config
- configuration instance used to obtain values to update this builder- Returns:
- updated builder instance
-
clearAuthStrategy
Clear existing value of this property.- Returns:
- updated builder instance
- See Also:
-
authStrategy
The singular authentication strategy to apply. This will be preferred overauthStrategies()
if both are present.- Parameters:
authStrategy
- the singular authentication strategy to be applied- Returns:
- updated builder instance
- See Also:
-
authStrategies
The list of authentication strategies that will be attempted byAbstractAuthenticationDetailsProvider
when one is called for. This is only used ifauthStrategy()
is not present.auto
- if present in the list, or if no value for this property exists, the behavior will be as ifconfig,config-file,instance-principals,resource-principal
were supplied instead.config
- theSimpleAuthenticationDetailsProvider
will be used, customized with other configuration properties described here.config-file
- theConfigFileAuthenticationDetailsProvider
will be used, customized with other configuration properties described here.instance-principals
- theInstancePrincipalsAuthenticationDetailsProvider
will be used.resource-principal
- theResourcePrincipalAuthenticationDetailsProvider
will be used.
If there are many strategy descriptors supplied, the first one that is deemed to be available or suitable will be used and all others will be ignored.
- Parameters:
authStrategies
- the list of authentication strategies that will be applied, defaulting toauto
- Returns:
- updated builder instance
- See Also:
-
addAuthStrategies
The list of authentication strategies that will be attempted byAbstractAuthenticationDetailsProvider
when one is called for. This is only used ifauthStrategy()
is not present.auto
- if present in the list, or if no value for this property exists, the behavior will be as ifconfig,config-file,instance-principals,resource-principal
were supplied instead.config
- theSimpleAuthenticationDetailsProvider
will be used, customized with other configuration properties described here.config-file
- theConfigFileAuthenticationDetailsProvider
will be used, customized with other configuration properties described here.instance-principals
- theInstancePrincipalsAuthenticationDetailsProvider
will be used.resource-principal
- theResourcePrincipalAuthenticationDetailsProvider
will be used.
If there are many strategy descriptors supplied, the first one that is deemed to be available or suitable will be used and all others will be ignored.
- Parameters:
authStrategies
- the list of authentication strategies that will be applied, defaulting toauto
- Returns:
- updated builder instance
- See Also:
-
clearConfigPath
Clear existing value of this property.- Returns:
- updated builder instance
- See Also:
-
configPath
The OCI configuration profile path.This configuration property has an effect only when
config-file
is, explicitly or implicitly, present in the value for theauthStrategies()
. This is also known asfileConfigIsPresent()
. When it is present, this property must also be present and then the ConfigFileReader.parse(String) method will be passed this value. It is expected to be passed with a valid OCI configuration file path.- Parameters:
configPath
- the OCI configuration profile path- Returns:
- updated builder instance
- See Also:
-
clearConfigProfile
Clear existing value of this property.- Returns:
- updated builder instance
- See Also:
-
configProfile
The OCI configuration/auth profile name.This configuration property has an effect only when
config-file
is, explicitly or implicitly, present in the value for theauthStrategies()
. This is also known asfileConfigIsPresent()
. When it is present, this property may also be optionally provided in order to override the default "DEFAULT".- Parameters:
configProfile
- the optional OCI configuration/auth profile name- Returns:
- updated builder instance
- See Also:
-
clearAuthFingerprint
Clear existing value of this property.- Returns:
- updated builder instance
- See Also:
-
authFingerprint
The OCI authentication fingerprint.This configuration property has an effect only when
config
is, explicitly or implicitly, present in the value for theauthStrategies()
. This is also known assimpleConfigIsPresent()
. When it is present, this property must be provided in order to set the API signing key's fingerprint. See SimpleAuthenticationDetailsProvider.getFingerprint() for more details.- Parameters:
authFingerprint
- the OCI authentication fingerprint- Returns:
- updated builder instance
- See Also:
-
authKeyFile
The OCI authentication key file.This configuration property has an effect only when
config
is, explicitly or implicitly, present in the value for theauthStrategies()
. This is also known assimpleConfigIsPresent()
. When it is present, this property must be provided in order to set the SimpleAuthenticationDetailsProvider.getPrivateKey(). This file must exist in theuser.home
directory. Alternatively, this property can be set using eitherauthPrivateKey()
or usingauthPrivateKeyPath()
.- Parameters:
authKeyFile
- the OCI authentication key file- Returns:
- updated builder instance
- See Also:
-
clearAuthPrivateKeyPath
Clear existing value of this property.- Returns:
- updated builder instance
- See Also:
-
authPrivateKeyPath
The OCI authentication key file path.This configuration property has an effect only when
config
is, explicitly or implicitly, present in the value for theauthStrategies()
. This is also known assimpleConfigIsPresent()
. When it is present, this property must be provided in order to set the SimpleAuthenticationDetailsProvider.getPrivateKey(). This file path is an alternative for usingauthKeyFile()
where the file must exist in theuser.home
directory. Alternatively, this property can be set usingauthPrivateKey()
.- Parameters:
authPrivateKeyPath
- the OCI authentication key file path- Returns:
- updated builder instance
- See Also:
-
clearAuthPrivateKey
Clear existing value of this property.- Returns:
- updated builder instance
- See Also:
-
authPrivateKey
The OCI authentication private key.This configuration property has an effect only when
config
is, explicitly or implicitly, present in the value for theauthStrategies()
. This is also known assimpleConfigIsPresent()
. When it is present, this property must be provided in order to set the SimpleAuthenticationDetailsProvider.getPrivateKey(). Alternatively, this property can be set using eitherauthKeyFile()
residing in theuser.home
directory, or usingauthPrivateKeyPath()
.- Parameters:
authPrivateKey
- the OCI authentication private key- Returns:
- updated builder instance
- See Also:
-
authPrivateKey
The OCI authentication private key.This configuration property has an effect only when
config
is, explicitly or implicitly, present in the value for theauthStrategies()
. This is also known assimpleConfigIsPresent()
. When it is present, this property must be provided in order to set the SimpleAuthenticationDetailsProvider.getPrivateKey(). Alternatively, this property can be set using eitherauthKeyFile()
residing in theuser.home
directory, or usingauthPrivateKeyPath()
.- Parameters:
authPrivateKey
- the OCI authentication private key- Returns:
- updated builder instance
- See Also:
-
clearAuthPassphrase
Clear existing value of this property.- Returns:
- updated builder instance
- See Also:
-
authPassphrase
The OCI authentication passphrase.This configuration property has an effect only when
config
is, explicitly or implicitly, present in the value for theauthStrategies()
. This is also known assimpleConfigIsPresent()
. When it is present, this property must be provided in order to set the SimpleAuthenticationDetailsProvider.getPassphraseCharacters().- Parameters:
authPassphrase
- the OCI authentication passphrase- Returns:
- updated builder instance
- See Also:
-
authPassphrase
The OCI authentication passphrase.This configuration property has an effect only when
config
is, explicitly or implicitly, present in the value for theauthStrategies()
. This is also known assimpleConfigIsPresent()
. When it is present, this property must be provided in order to set the SimpleAuthenticationDetailsProvider.getPassphraseCharacters().- Parameters:
authPassphrase
- the OCI authentication passphrase- Returns:
- updated builder instance
- See Also:
-
clearAuthRegion
Clear existing value of this property.- Returns:
- updated builder instance
- See Also:
-
authRegion
The OCI region.This configuration property has an effect only when
config
is, explicitly or implicitly, present in the value for theauthStrategies()
. This is also known assimpleConfigIsPresent()
. When it is present, either this property orRegionProvider
must be provide a value in order to set the ConfigFileAuthenticationDetailsProvider.getRegion().- Parameters:
authRegion
- the OCI region- Returns:
- updated builder instance
- See Also:
-
clearAuthTenantId
Clear existing value of this property.- Returns:
- updated builder instance
- See Also:
-
authTenantId
The OCI tenant id.This configuration property has an effect only when
config
is, explicitly or implicitly, present in the value for theauthStrategies()
. This is also known assimpleConfigIsPresent()
. When it is present, this property must be provided in order to set the ConfigFileAuthenticationDetailsProvider.getTenantId().- Parameters:
authTenantId
- the OCI tenant id- Returns:
- updated builder instance
- See Also:
-
clearAuthUserId
Clear existing value of this property.- Returns:
- updated builder instance
- See Also:
-
authUserId
The OCI user id.This configuration property has an effect only when
config
is, explicitly or implicitly, present in the value for theauthStrategies()
. When it is present, this property must be provided in order to set the ConfigFileAuthenticationDetailsProvider.getUserId().- Parameters:
authUserId
- the OCI user id- Returns:
- updated builder instance
- See Also:
-
imdsHostName
The OCI IMDS hostname.This configuration property is used to identify the metadata service url.
- Parameters:
imdsHostName
- the OCI IMDS hostname- Returns:
- updated builder instance
- See Also:
-
imdsTimeout
The OCI IMDS connection timeout. This is used to auto-detect availability.This configuration property is used when attempting to connect to the metadata service.
- Parameters:
imdsTimeout
- the OCI IMDS connection timeout- Returns:
- updated builder instance
- See Also:
-
authStrategy
The singular authentication strategy to apply. This will be preferred overauthStrategies()
if both are present.- Returns:
- the auth strategy
-
authStrategies
The list of authentication strategies that will be attempted byAbstractAuthenticationDetailsProvider
when one is called for. This is only used ifauthStrategy()
is not present.auto
- if present in the list, or if no value for this property exists, the behavior will be as ifconfig,config-file,instance-principals,resource-principal
were supplied instead.config
- theSimpleAuthenticationDetailsProvider
will be used, customized with other configuration properties described here.config-file
- theConfigFileAuthenticationDetailsProvider
will be used, customized with other configuration properties described here.instance-principals
- theInstancePrincipalsAuthenticationDetailsProvider
will be used.resource-principal
- theResourcePrincipalAuthenticationDetailsProvider
will be used.
If there are many strategy descriptors supplied, the first one that is deemed to be available or suitable will be used and all others will be ignored.
- Returns:
- the auth strategies
-
configPath
The OCI configuration profile path.This configuration property has an effect only when
config-file
is, explicitly or implicitly, present in the value for theauthStrategies()
. This is also known asfileConfigIsPresent()
. When it is present, this property must also be present and then the ConfigFileReader.parse(String) method will be passed this value. It is expected to be passed with a valid OCI configuration file path.- Returns:
- the config path
-
configProfile
The OCI configuration/auth profile name.This configuration property has an effect only when
config-file
is, explicitly or implicitly, present in the value for theauthStrategies()
. This is also known asfileConfigIsPresent()
. When it is present, this property may also be optionally provided in order to override the default "DEFAULT".- Returns:
- the config profile
-
authFingerprint
The OCI authentication fingerprint.This configuration property has an effect only when
config
is, explicitly or implicitly, present in the value for theauthStrategies()
. This is also known assimpleConfigIsPresent()
. When it is present, this property must be provided in order to set the API signing key's fingerprint. See SimpleAuthenticationDetailsProvider.getFingerprint() for more details.- Returns:
- the auth fingerprint
-
authKeyFile
The OCI authentication key file.This configuration property has an effect only when
config
is, explicitly or implicitly, present in the value for theauthStrategies()
. This is also known assimpleConfigIsPresent()
. When it is present, this property must be provided in order to set the SimpleAuthenticationDetailsProvider.getPrivateKey(). This file must exist in theuser.home
directory. Alternatively, this property can be set using eitherauthPrivateKey()
or usingauthPrivateKeyPath()
.- Returns:
- the auth key file
-
authPrivateKeyPath
The OCI authentication key file path.This configuration property has an effect only when
config
is, explicitly or implicitly, present in the value for theauthStrategies()
. This is also known assimpleConfigIsPresent()
. When it is present, this property must be provided in order to set the SimpleAuthenticationDetailsProvider.getPrivateKey(). This file path is an alternative for usingauthKeyFile()
where the file must exist in theuser.home
directory. Alternatively, this property can be set usingauthPrivateKey()
.- Returns:
- the auth private key path
-
authPrivateKey
The OCI authentication private key.This configuration property has an effect only when
config
is, explicitly or implicitly, present in the value for theauthStrategies()
. This is also known assimpleConfigIsPresent()
. When it is present, this property must be provided in order to set the SimpleAuthenticationDetailsProvider.getPrivateKey(). Alternatively, this property can be set using eitherauthKeyFile()
residing in theuser.home
directory, or usingauthPrivateKeyPath()
.- Returns:
- the auth private key
-
authPassphrase
The OCI authentication passphrase.This configuration property has an effect only when
config
is, explicitly or implicitly, present in the value for theauthStrategies()
. This is also known assimpleConfigIsPresent()
. When it is present, this property must be provided in order to set the SimpleAuthenticationDetailsProvider.getPassphraseCharacters().- Returns:
- the auth passphrase
-
authRegion
The OCI region.This configuration property has an effect only when
config
is, explicitly or implicitly, present in the value for theauthStrategies()
. This is also known assimpleConfigIsPresent()
. When it is present, either this property orRegionProvider
must be provide a value in order to set the ConfigFileAuthenticationDetailsProvider.getRegion().- Returns:
- the auth region
-
authTenantId
The OCI tenant id.This configuration property has an effect only when
config
is, explicitly or implicitly, present in the value for theauthStrategies()
. This is also known assimpleConfigIsPresent()
. When it is present, this property must be provided in order to set the ConfigFileAuthenticationDetailsProvider.getTenantId().- Returns:
- the auth tenant id
-
authUserId
The OCI user id.This configuration property has an effect only when
config
is, explicitly or implicitly, present in the value for theauthStrategies()
. When it is present, this property must be provided in order to set the ConfigFileAuthenticationDetailsProvider.getUserId().- Returns:
- the auth user id
-
imdsHostName
The OCI IMDS hostname.This configuration property is used to identify the metadata service url.
- Returns:
- the imds host name
-
imdsTimeout
The OCI IMDS connection timeout. This is used to auto-detect availability.This configuration property is used when attempting to connect to the metadata service.
- Returns:
- the imds timeout
-
config
If this instance was configured, this would be the config instance used.- Returns:
- config node used to configure this builder, or empty if not configured
-
toString
-