public interface GcpOptions extends GoogleApiDebugOptions, PipelineOptions
These options defer to the application default credentials for authentication. See the Google Auth Library for alternative mechanisms for creating credentials.
Modifier and Type | Interface and Description |
---|---|
static class |
GcpOptions.DefaultProjectFactory
Attempts to infer the default project based upon the environment this application is executing
within.
|
static class |
GcpOptions.EnableStreamingEngineFactory
EnableStreamingEngine defaults to false unless one of the two experiments is set.
|
static class |
GcpOptions.GcpOAuthScopesFactory
Returns the default set of OAuth scopes.
|
static class |
GcpOptions.GcpTempLocationFactory
Returns
PipelineOptions.getTempLocation() as the default GCP temp location. |
static class |
GcpOptions.GcpUserCredentialsFactory
Attempts to load the GCP credentials.
|
GoogleApiDebugOptions.GoogleApiTracer
PipelineOptions.AtomicLongFactory, PipelineOptions.CheckEnabled, PipelineOptions.DirectRunner, PipelineOptions.JobNameFactory, PipelineOptions.UserAgentFactory
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
STREAMING_ENGINE_EXPERIMENT
Experiment to turn on the Streaming Engine experiment.
|
static java.lang.String |
WINDMILL_SERVICE_EXPERIMENT
Deprecated.
Use STREAMING_ENGINE_EXPERIMENT instead.
|
Modifier and Type | Method and Description |
---|---|
java.lang.Class<? extends CredentialFactory> |
getCredentialFactoryClass()
The class of the credential factory that should be created and used to create credentials.
|
@Nullable java.lang.String |
getDataflowKmsKey()
GCP Cloud KMS key for Dataflow pipelines and
buckets created by GcpTempLocationFactory.
|
com.google.auth.Credentials |
getGcpCredential()
The credential instance that should be used to authenticate against GCP services.
|
java.util.List<java.lang.String> |
getGcpOauthScopes()
Controls the OAuth scopes that will be requested when creating
Credentials with the
GcpCredentialFactory (which is the default CredentialFactory ). |
@Nullable java.lang.String |
getGcpTempLocation()
A GCS path for storing temporary files in GCP.
|
@Nullable java.lang.String |
getImpersonateServiceAccount()
All API requests will be made as the given service account or target service account in an
impersonation delegation chain instead of the currently selected account.
|
java.lang.String |
getProject()
Project id to use when launching jobs.
|
java.lang.String |
getWorkerRegion()
The Compute Engine region (https://cloud.google.com/compute/docs/regions-zones/regions-zones)
in which worker processing should occur, e.g.
|
java.lang.String |
getWorkerZone()
The Compute Engine zone (https://cloud.google.com/compute/docs/regions-zones/regions-zones) in
which worker processing should occur, e.g.
|
java.lang.String |
getZone()
Deprecated.
Use
getWorkerZone() instead. |
boolean |
isEnableStreamingEngine() |
void |
setCredentialFactoryClass(java.lang.Class<? extends CredentialFactory> credentialFactoryClass) |
void |
setDataflowKmsKey(java.lang.String dataflowKmsKey) |
void |
setEnableStreamingEngine(boolean value) |
void |
setGcpCredential(com.google.auth.Credentials value) |
void |
setGcpOauthScopes(java.util.List<java.lang.String> oauthScopes) |
void |
setGcpTempLocation(java.lang.String value) |
void |
setImpersonateServiceAccount(java.lang.String impersonateServiceAccount) |
void |
setProject(java.lang.String value) |
void |
setWorkerRegion(java.lang.String workerRegion) |
void |
setWorkerZone(java.lang.String workerZone) |
void |
setZone(java.lang.String value)
Deprecated.
Use
setWorkerZone(java.lang.String) instead. |
getGoogleApiTrace, setGoogleApiTrace
as, getJobName, getOptionsId, getRunner, getStableUniqueNames, getTempLocation, getUserAgent, outputRuntimeOptions, setJobName, setOptionsId, setRunner, setStableUniqueNames, setTempLocation, setUserAgent
populateDisplayData
static final java.lang.String STREAMING_ENGINE_EXPERIMENT
@Deprecated static final java.lang.String WINDMILL_SERVICE_EXPERIMENT
@Default.InstanceFactory(value=GcpOptions.DefaultProjectFactory.class) java.lang.String getProject()
void setProject(java.lang.String value)
@Deprecated java.lang.String getZone()
getWorkerZone()
instead.Default is set on a per-service basis.
@Deprecated void setZone(java.lang.String value)
setWorkerZone(java.lang.String)
instead.java.lang.String getWorkerRegion()
getWorkerZone()
. If neither workerRegion nor workerZone is specified, default to same value
as region.void setWorkerRegion(java.lang.String workerRegion)
java.lang.String getWorkerZone()
getWorkerRegion()
. If neither workerRegion nor workerZone is specified, the Dataflow service
will choose a zone in region based on available capacity.void setWorkerZone(java.lang.String workerZone)
@Default.InstanceFactory(value=GcpOptions.GcpOAuthScopesFactory.class) java.util.List<java.lang.String> getGcpOauthScopes()
Credentials
with the
GcpCredentialFactory
(which is the default CredentialFactory
). If the credential
or credential factory
have
been set then this field may do nothing.void setGcpOauthScopes(java.util.List<java.lang.String> oauthScopes)
@Default.Class(value=GcpCredentialFactory.class) java.lang.Class<? extends CredentialFactory> getCredentialFactoryClass()
void setCredentialFactoryClass(java.lang.Class<? extends CredentialFactory> credentialFactoryClass)
@Default.InstanceFactory(value=GcpOptions.GcpUserCredentialsFactory.class) com.google.auth.Credentials getGcpCredential()
void setGcpCredential(com.google.auth.Credentials value)
@Nullable java.lang.String getImpersonateServiceAccount()
void setImpersonateServiceAccount(java.lang.String impersonateServiceAccount)
@Default.InstanceFactory(value=GcpOptions.EnableStreamingEngineFactory.class) boolean isEnableStreamingEngine()
void setEnableStreamingEngine(boolean value)
@Default.InstanceFactory(value=GcpOptions.GcpTempLocationFactory.class) @Nullable java.lang.String getGcpTempLocation()
Its default to PipelineOptions.getTempLocation()
.
void setGcpTempLocation(java.lang.String value)
@Experimental @Nullable java.lang.String getDataflowKmsKey()
void setDataflowKmsKey(java.lang.String dataflowKmsKey)