public static class GcpIamCredentialsAuthenticationOptions.GcpIamCredentialsAuthenticationOptionsBuilder extends Object
GcpIamCredentialsAuthenticationOptions
.public GcpIamCredentialsAuthenticationOptions.GcpIamCredentialsAuthenticationOptionsBuilder path(String path)
path
- must not be empty or null.this
GcpIamCredentialsAuthenticationOptions.GcpIamCredentialsAuthenticationOptionsBuilder
.public GcpIamCredentialsAuthenticationOptions.GcpIamCredentialsAuthenticationOptionsBuilder credentials(com.google.auth.oauth2.GoogleCredentials credentials)
credentials provider
.credentials
- must not be null.this
GcpIamCredentialsAuthenticationOptions.GcpIamCredentialsAuthenticationOptionsBuilder
.credentialsSupplier(GoogleCredentialsSupplier)
public GcpIamCredentialsAuthenticationOptions.GcpIamCredentialsAuthenticationOptionsBuilder credentialsSupplier(GoogleCredentialsSupplier credentialsSupplier)
GoogleCredentialsSupplier
, required to create a signed JWT.
Alternatively, configure static credentials
.credentialsSupplier
- must not be null.this
GcpIamCredentialsAuthenticationOptions.GcpIamCredentialsAuthenticationOptionsBuilder
.credentials(GoogleCredentials)
public GcpIamCredentialsAuthenticationOptions.GcpIamCredentialsAuthenticationOptionsBuilder serviceAccountId(String serviceAccountId)
ServiceAccountCredentials.getAccount()
.serviceAccountId
- the service account id (email) to usethis
GcpIamCredentialsAuthenticationOptions.GcpIamCredentialsAuthenticationOptionsBuilder
.public GcpIamCredentialsAuthenticationOptions.GcpIamCredentialsAuthenticationOptionsBuilder role(String role)
role
- must not be empty or null.this
GcpIamCredentialsAuthenticationOptions.GcpIamCredentialsAuthenticationOptionsBuilder
.public GcpIamCredentialsAuthenticationOptions.GcpIamCredentialsAuthenticationOptionsBuilder jwtValidity(Duration jwtValidity)
Duration
for the JWT expiration. This defaults to 15
minutes and cannot be more than a hour.jwtValidity
- must not be null.this
GcpIamCredentialsAuthenticationOptions.GcpIamCredentialsAuthenticationOptionsBuilder
.public GcpIamCredentialsAuthenticationOptions.GcpIamCredentialsAuthenticationOptionsBuilder clock(Clock clock)
Clock
used to calculate epoch seconds until the JWT
expiration.clock
- must not be null.this
GcpIamCredentialsAuthenticationOptions.GcpIamCredentialsAuthenticationOptionsBuilder
.public GcpIamCredentialsAuthenticationOptions build()
GcpIamCredentialsAuthenticationOptions
instance.GcpIamCredentialsAuthenticationOptions
.Copyright © 2016–2022 Pivotal Software, Inc.. All rights reserved.