Class GcpOptions.DefaultProjectFactory
java.lang.Object
org.apache.beam.sdk.extensions.gcp.options.GcpOptions.DefaultProjectFactory
- All Implemented Interfaces:
DefaultValueFactory<String>
- Enclosing interface:
GcpOptions
public static class GcpOptions.DefaultProjectFactory
extends Object
implements DefaultValueFactory<String>
Attempts to infer the default project based upon the environment this application is executing
within. Currently this only supports getting the active project from gcloud.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncreate
(PipelineOptions options) Creates a default value for a getter marked withDefault.InstanceFactory
.
-
Constructor Details
-
DefaultProjectFactory
public DefaultProjectFactory()
-
-
Method Details
-
create
Description copied from interface:DefaultValueFactory
Creates a default value for a getter marked withDefault.InstanceFactory
.- Specified by:
create
in interfaceDefaultValueFactory<String>
- Parameters:
options
- The current pipeline options.- Returns:
- The default value to be used for the annotated getter.
-