- 2.55.0 (latest)
- 2.54.0
- 2.53.0
- 2.51.0
- 2.50.0
- 2.49.0
- 2.48.0
- 2.47.0
- 2.46.0
- 2.45.0
- 2.44.0
- 2.43.0
- 2.42.0
- 2.41.0
- 2.39.0
- 2.38.0
- 2.37.0
- 2.36.0
- 2.35.0
- 2.34.0
- 2.33.0
- 2.32.0
- 2.31.0
- 2.30.0
- 2.29.0
- 2.26.0
- 2.25.0
- 2.24.0
- 2.23.0
- 2.22.0
- 2.21.0
- 2.20.0
- 2.19.0
- 2.18.0
- 2.17.0
- 2.16.0
- 2.15.0
- 2.14.0
- 2.13.0
- 2.11.0
- 2.10.0
- 2.9.0
- 2.8.0
- 2.7.0
- 2.6.0
- 2.5.4
- 2.4.3
- 2.3.6
public static final class ServiceConfig.Builder extends GeneratedMessageV3.Builder<ServiceConfig.Builder> implements ServiceConfigOrBuilder
Describes the Service being deployed. Currently Supported : Cloud Run (fully managed).
Protobuf type google.cloud.functions.v2.ServiceConfig
Inheritance
java.lang.Object > AbstractMessageLite.Builder<MessageType,BuilderType> > AbstractMessage.Builder<BuilderType> > GeneratedMessageV3.Builder > ServiceConfig.BuilderImplements
ServiceConfigOrBuilderStatic Methods
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
Returns | |
---|---|
Type | Description |
Descriptor |
Methods
addAllSecretEnvironmentVariables(Iterable<? extends SecretEnvVar> values)
public ServiceConfig.Builder addAllSecretEnvironmentVariables(Iterable<? extends SecretEnvVar> values)
Secret environment variables configuration.
repeated .google.cloud.functions.v2.SecretEnvVar secret_environment_variables = 17;
Parameter | |
---|---|
Name | Description |
values | Iterable<? extends com.google.cloud.functions.v2.SecretEnvVar> |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder |
addAllSecretVolumes(Iterable<? extends SecretVolume> values)
public ServiceConfig.Builder addAllSecretVolumes(Iterable<? extends SecretVolume> values)
Secret volumes configuration.
repeated .google.cloud.functions.v2.SecretVolume secret_volumes = 19;
Parameter | |
---|---|
Name | Description |
values | Iterable<? extends com.google.cloud.functions.v2.SecretVolume> |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder |
addSecretEnvironmentVariables(SecretEnvVar value)
public ServiceConfig.Builder addSecretEnvironmentVariables(SecretEnvVar value)
Secret environment variables configuration.
repeated .google.cloud.functions.v2.SecretEnvVar secret_environment_variables = 17;
Parameter | |
---|---|
Name | Description |
value | SecretEnvVar |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder |
addSecretEnvironmentVariables(SecretEnvVar.Builder builderForValue)
public ServiceConfig.Builder addSecretEnvironmentVariables(SecretEnvVar.Builder builderForValue)
Secret environment variables configuration.
repeated .google.cloud.functions.v2.SecretEnvVar secret_environment_variables = 17;
Parameter | |
---|---|
Name | Description |
builderForValue | SecretEnvVar.Builder |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder |
addSecretEnvironmentVariables(int index, SecretEnvVar value)
public ServiceConfig.Builder addSecretEnvironmentVariables(int index, SecretEnvVar value)
Secret environment variables configuration.
repeated .google.cloud.functions.v2.SecretEnvVar secret_environment_variables = 17;
Parameters | |
---|---|
Name | Description |
index | int |
value | SecretEnvVar |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder |
addSecretEnvironmentVariables(int index, SecretEnvVar.Builder builderForValue)
public ServiceConfig.Builder addSecretEnvironmentVariables(int index, SecretEnvVar.Builder builderForValue)
Secret environment variables configuration.
repeated .google.cloud.functions.v2.SecretEnvVar secret_environment_variables = 17;
Parameters | |
---|---|
Name | Description |
index | int |
builderForValue | SecretEnvVar.Builder |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder |
addSecretEnvironmentVariablesBuilder()
public SecretEnvVar.Builder addSecretEnvironmentVariablesBuilder()
Secret environment variables configuration.
repeated .google.cloud.functions.v2.SecretEnvVar secret_environment_variables = 17;
Returns | |
---|---|
Type | Description |
SecretEnvVar.Builder |
addSecretEnvironmentVariablesBuilder(int index)
public SecretEnvVar.Builder addSecretEnvironmentVariablesBuilder(int index)
Secret environment variables configuration.
repeated .google.cloud.functions.v2.SecretEnvVar secret_environment_variables = 17;
Parameter | |
---|---|
Name | Description |
index | int |
Returns | |
---|---|
Type | Description |
SecretEnvVar.Builder |
addSecretVolumes(SecretVolume value)
public ServiceConfig.Builder addSecretVolumes(SecretVolume value)
Secret volumes configuration.
repeated .google.cloud.functions.v2.SecretVolume secret_volumes = 19;
Parameter | |
---|---|
Name | Description |
value | SecretVolume |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder |
addSecretVolumes(SecretVolume.Builder builderForValue)
public ServiceConfig.Builder addSecretVolumes(SecretVolume.Builder builderForValue)
Secret volumes configuration.
repeated .google.cloud.functions.v2.SecretVolume secret_volumes = 19;
Parameter | |
---|---|
Name | Description |
builderForValue | SecretVolume.Builder |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder |
addSecretVolumes(int index, SecretVolume value)
public ServiceConfig.Builder addSecretVolumes(int index, SecretVolume value)
Secret volumes configuration.
repeated .google.cloud.functions.v2.SecretVolume secret_volumes = 19;
Parameters | |
---|---|
Name | Description |
index | int |
value | SecretVolume |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder |
addSecretVolumes(int index, SecretVolume.Builder builderForValue)
public ServiceConfig.Builder addSecretVolumes(int index, SecretVolume.Builder builderForValue)
Secret volumes configuration.
repeated .google.cloud.functions.v2.SecretVolume secret_volumes = 19;
Parameters | |
---|---|
Name | Description |
index | int |
builderForValue | SecretVolume.Builder |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder |
addSecretVolumesBuilder()
public SecretVolume.Builder addSecretVolumesBuilder()
Secret volumes configuration.
repeated .google.cloud.functions.v2.SecretVolume secret_volumes = 19;
Returns | |
---|---|
Type | Description |
SecretVolume.Builder |
addSecretVolumesBuilder(int index)
public SecretVolume.Builder addSecretVolumesBuilder(int index)
Secret volumes configuration.
repeated .google.cloud.functions.v2.SecretVolume secret_volumes = 19;
Parameter | |
---|---|
Name | Description |
index | int |
Returns | |
---|---|
Type | Description |
SecretVolume.Builder |
build()
public ServiceConfig build()
Returns | |
---|---|
Type | Description |
ServiceConfig |
buildPartial()
public ServiceConfig buildPartial()
Returns | |
---|---|
Type | Description |
ServiceConfig |
clear()
public ServiceConfig.Builder clear()
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder |
clearAllTrafficOnLatestRevision()
public ServiceConfig.Builder clearAllTrafficOnLatestRevision()
Whether 100% of traffic is routed to the latest revision. On CreateFunction and UpdateFunction, when set to true, the revision being deployed will serve 100% of traffic, ignoring any traffic split settings, if any. On GetFunction, true will be returned if the latest revision is serving 100% of traffic.
bool all_traffic_on_latest_revision = 16;
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
clearAvailableCpu()
public ServiceConfig.Builder clearAvailableCpu()
[Preview] The number of CPUs used in a single container instance. Default value is calculated from available memory. Supports the same values as Cloud Run, see https://cloud.google.com/run/docs/reference/rest/v1/Container#resourcerequirements Example: "1" indicates 1 vCPU
string available_cpu = 22;
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
clearAvailableMemory()
public ServiceConfig.Builder clearAvailableMemory()
The amount of memory available for a function. Defaults to 256M. Supported units are k, M, G, Mi, Gi. If no unit is supplied the value is interpreted as bytes. See https://github.com/kubernetes/kubernetes/blob/master/staging/src/k8s.io/apimachinery/pkg/api/resource/quantity.go a full description.
string available_memory = 13;
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
clearEnvironmentVariables()
public ServiceConfig.Builder clearEnvironmentVariables()
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder |
clearIngressSettings()
public ServiceConfig.Builder clearIngressSettings()
The ingress settings for the function, controlling what traffic can reach it.
.google.cloud.functions.v2.ServiceConfig.IngressSettings ingress_settings = 8;
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
clearMaxInstanceCount()
public ServiceConfig.Builder clearMaxInstanceCount()
The limit on the maximum number of function instances that may coexist at a given time.
In some cases, such as rapid traffic surges, Cloud Functions may, for a short period of time, create more instances than the specified max instances limit. If your function cannot tolerate this temporary behavior, you may want to factor in a safety margin and set a lower max instances value than your function can tolerate.
See the Max Instances Guide for more details.
int32 max_instance_count = 5;
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
clearMaxInstanceRequestConcurrency()
public ServiceConfig.Builder clearMaxInstanceRequestConcurrency()
[Preview] Sets the maximum number of concurrent requests that each instance can receive. Defaults to 1.
int32 max_instance_request_concurrency = 20;
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
clearMinInstanceCount()
public ServiceConfig.Builder clearMinInstanceCount()
The limit on the minimum number of function instances that may coexist at a given time.
Function instances are kept in idle state for a short period after they finished executing the request to reduce cold start time for subsequent requests. Setting a minimum instance count will ensure that the given number of instances are kept running in idle state always. This can help with cold start times when jump in incoming request count occurs after the idle instance would have been stopped in the default case.
int32 min_instance_count = 12;
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
clearRevision()
public ServiceConfig.Builder clearRevision()
Output only. The name of service revision.
string revision = 18 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
clearSecretEnvironmentVariables()
public ServiceConfig.Builder clearSecretEnvironmentVariables()
Secret environment variables configuration.
repeated .google.cloud.functions.v2.SecretEnvVar secret_environment_variables = 17;
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder |
clearSecretVolumes()
public ServiceConfig.Builder clearSecretVolumes()
Secret volumes configuration.
repeated .google.cloud.functions.v2.SecretVolume secret_volumes = 19;
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder |
clearSecurityLevel()
public ServiceConfig.Builder clearSecurityLevel()
Security level configure whether the function only accepts https. This configuration is only applicable to 1st Gen functions with Http trigger. By default https is optional for 1st Gen functions; 2nd Gen functions are https ONLY.
.google.cloud.functions.v2.ServiceConfig.SecurityLevel security_level = 21;
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
clearService()
public ServiceConfig.Builder clearService()
Output only. Name of the service associated with a Function.
The format of this field is
projects/{project}/locations/{region}/services/{service}
string service = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... }
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
clearServiceAccountEmail()
public ServiceConfig.Builder clearServiceAccountEmail()
The email of the service's service account. If empty, defaults to
{project_number}-compute@developer.gserviceaccount.com
.
string service_account_email = 10;
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
clearTimeoutSeconds()
public ServiceConfig.Builder clearTimeoutSeconds()
The function execution timeout. Execution is considered failed and can be terminated if the function is not completed at the end of the timeout period. Defaults to 60 seconds.
int32 timeout_seconds = 2;
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
clearUri()
public ServiceConfig.Builder clearUri()
Output only. URI of the Service deployed.
string uri = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
clearVpcConnector()
public ServiceConfig.Builder clearVpcConnector()
The Serverless VPC Access connector that this cloud function can connect
to. The format of this field is projects/*/locations/*/connectors/*
.
string vpc_connector = 6 [(.google.api.resource_reference) = { ... }
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
clearVpcConnectorEgressSettings()
public ServiceConfig.Builder clearVpcConnectorEgressSettings()
The egress settings for the connector, controlling what traffic is diverted through it.
.google.cloud.functions.v2.ServiceConfig.VpcConnectorEgressSettings vpc_connector_egress_settings = 7;
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
containsEnvironmentVariables(String key)
public boolean containsEnvironmentVariables(String key)
Environment variables that shall be available during function execution.
map<string, string> environment_variables = 4;
Parameter | |
---|---|
Name | Description |
key | String |
Returns | |
---|---|
Type | Description |
boolean |
getAllTrafficOnLatestRevision()
public boolean getAllTrafficOnLatestRevision()
Whether 100% of traffic is routed to the latest revision. On CreateFunction and UpdateFunction, when set to true, the revision being deployed will serve 100% of traffic, ignoring any traffic split settings, if any. On GetFunction, true will be returned if the latest revision is serving 100% of traffic.
bool all_traffic_on_latest_revision = 16;
Returns | |
---|---|
Type | Description |
boolean | The allTrafficOnLatestRevision. |
getAvailableCpu()
public String getAvailableCpu()
[Preview] The number of CPUs used in a single container instance. Default value is calculated from available memory. Supports the same values as Cloud Run, see https://cloud.google.com/run/docs/reference/rest/v1/Container#resourcerequirements Example: "1" indicates 1 vCPU
string available_cpu = 22;
Returns | |
---|---|
Type | Description |
String | The availableCpu. |
getAvailableCpuBytes()
public ByteString getAvailableCpuBytes()
[Preview] The number of CPUs used in a single container instance. Default value is calculated from available memory. Supports the same values as Cloud Run, see https://cloud.google.com/run/docs/reference/rest/v1/Container#resourcerequirements Example: "1" indicates 1 vCPU
string available_cpu = 22;
Returns | |
---|---|
Type | Description |
ByteString | The bytes for availableCpu. |
getAvailableMemory()
public String getAvailableMemory()
The amount of memory available for a function. Defaults to 256M. Supported units are k, M, G, Mi, Gi. If no unit is supplied the value is interpreted as bytes. See https://github.com/kubernetes/kubernetes/blob/master/staging/src/k8s.io/apimachinery/pkg/api/resource/quantity.go a full description.
string available_memory = 13;
Returns | |
---|---|
Type | Description |
String | The availableMemory. |
getAvailableMemoryBytes()
public ByteString getAvailableMemoryBytes()
The amount of memory available for a function. Defaults to 256M. Supported units are k, M, G, Mi, Gi. If no unit is supplied the value is interpreted as bytes. See https://github.com/kubernetes/kubernetes/blob/master/staging/src/k8s.io/apimachinery/pkg/api/resource/quantity.go a full description.
string available_memory = 13;
Returns | |
---|---|
Type | Description |
ByteString | The bytes for availableMemory. |
getDefaultInstanceForType()
public ServiceConfig getDefaultInstanceForType()
Returns | |
---|---|
Type | Description |
ServiceConfig |
getDescriptorForType()
public Descriptors.Descriptor getDescriptorForType()
Returns | |
---|---|
Type | Description |
Descriptor |
getEnvironmentVariables()
public Map<String,String> getEnvironmentVariables()
Use #getEnvironmentVariablesMap() instead.
Returns | |
---|---|
Type | Description |
Map<String,String> |
getEnvironmentVariablesCount()
public int getEnvironmentVariablesCount()
Environment variables that shall be available during function execution.
map<string, string> environment_variables = 4;
Returns | |
---|---|
Type | Description |
int |
getEnvironmentVariablesMap()
public Map<String,String> getEnvironmentVariablesMap()
Environment variables that shall be available during function execution.
map<string, string> environment_variables = 4;
Returns | |
---|---|
Type | Description |
Map<String,String> |
getEnvironmentVariablesOrDefault(String key, String defaultValue)
public String getEnvironmentVariablesOrDefault(String key, String defaultValue)
Environment variables that shall be available during function execution.
map<string, string> environment_variables = 4;
Parameters | |
---|---|
Name | Description |
key | String |
defaultValue | String |
Returns | |
---|---|
Type | Description |
String |
getEnvironmentVariablesOrThrow(String key)
public String getEnvironmentVariablesOrThrow(String key)
Environment variables that shall be available during function execution.
map<string, string> environment_variables = 4;
Parameter | |
---|---|
Name | Description |
key | String |
Returns | |
---|---|
Type | Description |
String |
getIngressSettings()
public ServiceConfig.IngressSettings getIngressSettings()
The ingress settings for the function, controlling what traffic can reach it.
.google.cloud.functions.v2.ServiceConfig.IngressSettings ingress_settings = 8;
Returns | |
---|---|
Type | Description |
ServiceConfig.IngressSettings | The ingressSettings. |
getIngressSettingsValue()
public int getIngressSettingsValue()
The ingress settings for the function, controlling what traffic can reach it.
.google.cloud.functions.v2.ServiceConfig.IngressSettings ingress_settings = 8;
Returns | |
---|---|
Type | Description |
int | The enum numeric value on the wire for ingressSettings. |
getMaxInstanceCount()
public int getMaxInstanceCount()
The limit on the maximum number of function instances that may coexist at a given time.
In some cases, such as rapid traffic surges, Cloud Functions may, for a short period of time, create more instances than the specified max instances limit. If your function cannot tolerate this temporary behavior, you may want to factor in a safety margin and set a lower max instances value than your function can tolerate.
See the Max Instances Guide for more details.
int32 max_instance_count = 5;
Returns | |
---|---|
Type | Description |
int | The maxInstanceCount. |
getMaxInstanceRequestConcurrency()
public int getMaxInstanceRequestConcurrency()
[Preview] Sets the maximum number of concurrent requests that each instance can receive. Defaults to 1.
int32 max_instance_request_concurrency = 20;
Returns | |
---|---|
Type | Description |
int | The maxInstanceRequestConcurrency. |
getMinInstanceCount()
public int getMinInstanceCount()
The limit on the minimum number of function instances that may coexist at a given time.
Function instances are kept in idle state for a short period after they finished executing the request to reduce cold start time for subsequent requests. Setting a minimum instance count will ensure that the given number of instances are kept running in idle state always. This can help with cold start times when jump in incoming request count occurs after the idle instance would have been stopped in the default case.
int32 min_instance_count = 12;
Returns | |
---|---|
Type | Description |
int | The minInstanceCount. |
getMutableEnvironmentVariables()
public Map<String,String> getMutableEnvironmentVariables()
Use alternate mutation accessors instead.
Returns | |
---|---|
Type | Description |
Map<String,String> |
getRevision()
public String getRevision()
Output only. The name of service revision.
string revision = 18 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns | |
---|---|
Type | Description |
String | The revision. |
getRevisionBytes()
public ByteString getRevisionBytes()
Output only. The name of service revision.
string revision = 18 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns | |
---|---|
Type | Description |
ByteString | The bytes for revision. |
getSecretEnvironmentVariables(int index)
public SecretEnvVar getSecretEnvironmentVariables(int index)
Secret environment variables configuration.
repeated .google.cloud.functions.v2.SecretEnvVar secret_environment_variables = 17;
Parameter | |
---|---|
Name | Description |
index | int |
Returns | |
---|---|
Type | Description |
SecretEnvVar |
getSecretEnvironmentVariablesBuilder(int index)
public SecretEnvVar.Builder getSecretEnvironmentVariablesBuilder(int index)
Secret environment variables configuration.
repeated .google.cloud.functions.v2.SecretEnvVar secret_environment_variables = 17;
Parameter | |
---|---|
Name | Description |
index | int |
Returns | |
---|---|
Type | Description |
SecretEnvVar.Builder |
getSecretEnvironmentVariablesBuilderList()
public List<SecretEnvVar.Builder> getSecretEnvironmentVariablesBuilderList()
Secret environment variables configuration.
repeated .google.cloud.functions.v2.SecretEnvVar secret_environment_variables = 17;
Returns | |
---|---|
Type | Description |
List<Builder> |
getSecretEnvironmentVariablesCount()
public int getSecretEnvironmentVariablesCount()
Secret environment variables configuration.
repeated .google.cloud.functions.v2.SecretEnvVar secret_environment_variables = 17;
Returns | |
---|---|
Type | Description |
int |
getSecretEnvironmentVariablesList()
public List<SecretEnvVar> getSecretEnvironmentVariablesList()
Secret environment variables configuration.
repeated .google.cloud.functions.v2.SecretEnvVar secret_environment_variables = 17;
Returns | |
---|---|
Type | Description |
List<SecretEnvVar> |
getSecretEnvironmentVariablesOrBuilder(int index)
public SecretEnvVarOrBuilder getSecretEnvironmentVariablesOrBuilder(int index)
Secret environment variables configuration.
repeated .google.cloud.functions.v2.SecretEnvVar secret_environment_variables = 17;
Parameter | |
---|---|
Name | Description |
index | int |
Returns | |
---|---|
Type | Description |
SecretEnvVarOrBuilder |
getSecretEnvironmentVariablesOrBuilderList()
public List<? extends SecretEnvVarOrBuilder> getSecretEnvironmentVariablesOrBuilderList()
Secret environment variables configuration.
repeated .google.cloud.functions.v2.SecretEnvVar secret_environment_variables = 17;
Returns | |
---|---|
Type | Description |
List<? extends com.google.cloud.functions.v2.SecretEnvVarOrBuilder> |
getSecretVolumes(int index)
public SecretVolume getSecretVolumes(int index)
Secret volumes configuration.
repeated .google.cloud.functions.v2.SecretVolume secret_volumes = 19;
Parameter | |
---|---|
Name | Description |
index | int |
Returns | |
---|---|
Type | Description |
SecretVolume |
getSecretVolumesBuilder(int index)
public SecretVolume.Builder getSecretVolumesBuilder(int index)
Secret volumes configuration.
repeated .google.cloud.functions.v2.SecretVolume secret_volumes = 19;
Parameter | |
---|---|
Name | Description |
index | int |
Returns | |
---|---|
Type | Description |
SecretVolume.Builder |
getSecretVolumesBuilderList()
public List<SecretVolume.Builder> getSecretVolumesBuilderList()
Secret volumes configuration.
repeated .google.cloud.functions.v2.SecretVolume secret_volumes = 19;
Returns | |
---|---|
Type | Description |
List<Builder> |
getSecretVolumesCount()
public int getSecretVolumesCount()
Secret volumes configuration.
repeated .google.cloud.functions.v2.SecretVolume secret_volumes = 19;
Returns | |
---|---|
Type | Description |
int |
getSecretVolumesList()
public List<SecretVolume> getSecretVolumesList()
Secret volumes configuration.
repeated .google.cloud.functions.v2.SecretVolume secret_volumes = 19;
Returns | |
---|---|
Type | Description |
List<SecretVolume> |
getSecretVolumesOrBuilder(int index)
public SecretVolumeOrBuilder getSecretVolumesOrBuilder(int index)
Secret volumes configuration.
repeated .google.cloud.functions.v2.SecretVolume secret_volumes = 19;
Parameter | |
---|---|
Name | Description |
index | int |
Returns | |
---|---|
Type | Description |
SecretVolumeOrBuilder |
getSecretVolumesOrBuilderList()
public List<? extends SecretVolumeOrBuilder> getSecretVolumesOrBuilderList()
Secret volumes configuration.
repeated .google.cloud.functions.v2.SecretVolume secret_volumes = 19;
Returns | |
---|---|
Type | Description |
List<? extends com.google.cloud.functions.v2.SecretVolumeOrBuilder> |
getSecurityLevel()
public ServiceConfig.SecurityLevel getSecurityLevel()
Security level configure whether the function only accepts https. This configuration is only applicable to 1st Gen functions with Http trigger. By default https is optional for 1st Gen functions; 2nd Gen functions are https ONLY.
.google.cloud.functions.v2.ServiceConfig.SecurityLevel security_level = 21;
Returns | |
---|---|
Type | Description |
ServiceConfig.SecurityLevel | The securityLevel. |
getSecurityLevelValue()
public int getSecurityLevelValue()
Security level configure whether the function only accepts https. This configuration is only applicable to 1st Gen functions with Http trigger. By default https is optional for 1st Gen functions; 2nd Gen functions are https ONLY.
.google.cloud.functions.v2.ServiceConfig.SecurityLevel security_level = 21;
Returns | |
---|---|
Type | Description |
int | The enum numeric value on the wire for securityLevel. |
getService()
public String getService()
Output only. Name of the service associated with a Function.
The format of this field is
projects/{project}/locations/{region}/services/{service}
string service = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... }
Returns | |
---|---|
Type | Description |
String | The service. |
getServiceAccountEmail()
public String getServiceAccountEmail()
The email of the service's service account. If empty, defaults to
{project_number}-compute@developer.gserviceaccount.com
.
string service_account_email = 10;
Returns | |
---|---|
Type | Description |
String | The serviceAccountEmail. |
getServiceAccountEmailBytes()
public ByteString getServiceAccountEmailBytes()
The email of the service's service account. If empty, defaults to
{project_number}-compute@developer.gserviceaccount.com
.
string service_account_email = 10;
Returns | |
---|---|
Type | Description |
ByteString | The bytes for serviceAccountEmail. |
getServiceBytes()
public ByteString getServiceBytes()
Output only. Name of the service associated with a Function.
The format of this field is
projects/{project}/locations/{region}/services/{service}
string service = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... }
Returns | |
---|---|
Type | Description |
ByteString | The bytes for service. |
getTimeoutSeconds()
public int getTimeoutSeconds()
The function execution timeout. Execution is considered failed and can be terminated if the function is not completed at the end of the timeout period. Defaults to 60 seconds.
int32 timeout_seconds = 2;
Returns | |
---|---|
Type | Description |
int | The timeoutSeconds. |
getUri()
public String getUri()
Output only. URI of the Service deployed.
string uri = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns | |
---|---|
Type | Description |
String | The uri. |
getUriBytes()
public ByteString getUriBytes()
Output only. URI of the Service deployed.
string uri = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns | |
---|---|
Type | Description |
ByteString | The bytes for uri. |
getVpcConnector()
public String getVpcConnector()
The Serverless VPC Access connector that this cloud function can connect
to. The format of this field is projects/*/locations/*/connectors/*
.
string vpc_connector = 6 [(.google.api.resource_reference) = { ... }
Returns | |
---|---|
Type | Description |
String | The vpcConnector. |
getVpcConnectorBytes()
public ByteString getVpcConnectorBytes()
The Serverless VPC Access connector that this cloud function can connect
to. The format of this field is projects/*/locations/*/connectors/*
.
string vpc_connector = 6 [(.google.api.resource_reference) = { ... }
Returns | |
---|---|
Type | Description |
ByteString | The bytes for vpcConnector. |
getVpcConnectorEgressSettings()
public ServiceConfig.VpcConnectorEgressSettings getVpcConnectorEgressSettings()
The egress settings for the connector, controlling what traffic is diverted through it.
.google.cloud.functions.v2.ServiceConfig.VpcConnectorEgressSettings vpc_connector_egress_settings = 7;
Returns | |
---|---|
Type | Description |
ServiceConfig.VpcConnectorEgressSettings | The vpcConnectorEgressSettings. |
getVpcConnectorEgressSettingsValue()
public int getVpcConnectorEgressSettingsValue()
The egress settings for the connector, controlling what traffic is diverted through it.
.google.cloud.functions.v2.ServiceConfig.VpcConnectorEgressSettings vpc_connector_egress_settings = 7;
Returns | |
---|---|
Type | Description |
int | The enum numeric value on the wire for vpcConnectorEgressSettings. |
internalGetFieldAccessorTable()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns | |
---|---|
Type | Description |
FieldAccessorTable |
internalGetMapField(int number)
protected MapField internalGetMapField(int number)
Parameter | |
---|---|
Name | Description |
number | int |
Returns | |
---|---|
Type | Description |
MapField |
internalGetMutableMapField(int number)
protected MapField internalGetMutableMapField(int number)
Parameter | |
---|---|
Name | Description |
number | int |
Returns | |
---|---|
Type | Description |
MapField |
isInitialized()
public final boolean isInitialized()
Returns | |
---|---|
Type | Description |
boolean |
mergeFrom(ServiceConfig other)
public ServiceConfig.Builder mergeFrom(ServiceConfig other)
Parameter | |
---|---|
Name | Description |
other | ServiceConfig |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder |
mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
public ServiceConfig.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters | |
---|---|
Name | Description |
input | CodedInputStream |
extensionRegistry | ExtensionRegistryLite |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder |
Exceptions | |
---|---|
Type | Description |
IOException |
mergeFrom(Message other)
public ServiceConfig.Builder mergeFrom(Message other)
Parameter | |
---|---|
Name | Description |
other | Message |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder |
mergeUnknownFields(UnknownFieldSet unknownFields)
public final ServiceConfig.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter | |
---|---|
Name | Description |
unknownFields | UnknownFieldSet |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder |
putAllEnvironmentVariables(Map<String,String> values)
public ServiceConfig.Builder putAllEnvironmentVariables(Map<String,String> values)
Environment variables that shall be available during function execution.
map<string, string> environment_variables = 4;
Parameter | |
---|---|
Name | Description |
values | Map<String,String> |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder |
putEnvironmentVariables(String key, String value)
public ServiceConfig.Builder putEnvironmentVariables(String key, String value)
Environment variables that shall be available during function execution.
map<string, string> environment_variables = 4;
Parameters | |
---|---|
Name | Description |
key | String |
value | String |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder |
removeEnvironmentVariables(String key)
public ServiceConfig.Builder removeEnvironmentVariables(String key)
Environment variables that shall be available during function execution.
map<string, string> environment_variables = 4;
Parameter | |
---|---|
Name | Description |
key | String |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder |
removeSecretEnvironmentVariables(int index)
public ServiceConfig.Builder removeSecretEnvironmentVariables(int index)
Secret environment variables configuration.
repeated .google.cloud.functions.v2.SecretEnvVar secret_environment_variables = 17;
Parameter | |
---|---|
Name | Description |
index | int |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder |
removeSecretVolumes(int index)
public ServiceConfig.Builder removeSecretVolumes(int index)
Secret volumes configuration.
repeated .google.cloud.functions.v2.SecretVolume secret_volumes = 19;
Parameter | |
---|---|
Name | Description |
index | int |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder |
setAllTrafficOnLatestRevision(boolean value)
public ServiceConfig.Builder setAllTrafficOnLatestRevision(boolean value)
Whether 100% of traffic is routed to the latest revision. On CreateFunction and UpdateFunction, when set to true, the revision being deployed will serve 100% of traffic, ignoring any traffic split settings, if any. On GetFunction, true will be returned if the latest revision is serving 100% of traffic.
bool all_traffic_on_latest_revision = 16;
Parameter | |
---|---|
Name | Description |
value | boolean The allTrafficOnLatestRevision to set. |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
setAvailableCpu(String value)
public ServiceConfig.Builder setAvailableCpu(String value)
[Preview] The number of CPUs used in a single container instance. Default value is calculated from available memory. Supports the same values as Cloud Run, see https://cloud.google.com/run/docs/reference/rest/v1/Container#resourcerequirements Example: "1" indicates 1 vCPU
string available_cpu = 22;
Parameter | |
---|---|
Name | Description |
value | String The availableCpu to set. |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
setAvailableCpuBytes(ByteString value)
public ServiceConfig.Builder setAvailableCpuBytes(ByteString value)
[Preview] The number of CPUs used in a single container instance. Default value is calculated from available memory. Supports the same values as Cloud Run, see https://cloud.google.com/run/docs/reference/rest/v1/Container#resourcerequirements Example: "1" indicates 1 vCPU
string available_cpu = 22;
Parameter | |
---|---|
Name | Description |
value | ByteString The bytes for availableCpu to set. |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
setAvailableMemory(String value)
public ServiceConfig.Builder setAvailableMemory(String value)
The amount of memory available for a function. Defaults to 256M. Supported units are k, M, G, Mi, Gi. If no unit is supplied the value is interpreted as bytes. See https://github.com/kubernetes/kubernetes/blob/master/staging/src/k8s.io/apimachinery/pkg/api/resource/quantity.go a full description.
string available_memory = 13;
Parameter | |
---|---|
Name | Description |
value | String The availableMemory to set. |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
setAvailableMemoryBytes(ByteString value)
public ServiceConfig.Builder setAvailableMemoryBytes(ByteString value)
The amount of memory available for a function. Defaults to 256M. Supported units are k, M, G, Mi, Gi. If no unit is supplied the value is interpreted as bytes. See https://github.com/kubernetes/kubernetes/blob/master/staging/src/k8s.io/apimachinery/pkg/api/resource/quantity.go a full description.
string available_memory = 13;
Parameter | |
---|---|
Name | Description |
value | ByteString The bytes for availableMemory to set. |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
setIngressSettings(ServiceConfig.IngressSettings value)
public ServiceConfig.Builder setIngressSettings(ServiceConfig.IngressSettings value)
The ingress settings for the function, controlling what traffic can reach it.
.google.cloud.functions.v2.ServiceConfig.IngressSettings ingress_settings = 8;
Parameter | |
---|---|
Name | Description |
value | ServiceConfig.IngressSettings The ingressSettings to set. |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
setIngressSettingsValue(int value)
public ServiceConfig.Builder setIngressSettingsValue(int value)
The ingress settings for the function, controlling what traffic can reach it.
.google.cloud.functions.v2.ServiceConfig.IngressSettings ingress_settings = 8;
Parameter | |
---|---|
Name | Description |
value | int The enum numeric value on the wire for ingressSettings to set. |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
setMaxInstanceCount(int value)
public ServiceConfig.Builder setMaxInstanceCount(int value)
The limit on the maximum number of function instances that may coexist at a given time.
In some cases, such as rapid traffic surges, Cloud Functions may, for a short period of time, create more instances than the specified max instances limit. If your function cannot tolerate this temporary behavior, you may want to factor in a safety margin and set a lower max instances value than your function can tolerate.
See the Max Instances Guide for more details.
int32 max_instance_count = 5;
Parameter | |
---|---|
Name | Description |
value | int The maxInstanceCount to set. |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
setMaxInstanceRequestConcurrency(int value)
public ServiceConfig.Builder setMaxInstanceRequestConcurrency(int value)
[Preview] Sets the maximum number of concurrent requests that each instance can receive. Defaults to 1.
int32 max_instance_request_concurrency = 20;
Parameter | |
---|---|
Name | Description |
value | int The maxInstanceRequestConcurrency to set. |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
setMinInstanceCount(int value)
public ServiceConfig.Builder setMinInstanceCount(int value)
The limit on the minimum number of function instances that may coexist at a given time.
Function instances are kept in idle state for a short period after they finished executing the request to reduce cold start time for subsequent requests. Setting a minimum instance count will ensure that the given number of instances are kept running in idle state always. This can help with cold start times when jump in incoming request count occurs after the idle instance would have been stopped in the default case.
int32 min_instance_count = 12;
Parameter | |
---|---|
Name | Description |
value | int The minInstanceCount to set. |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
setRevision(String value)
public ServiceConfig.Builder setRevision(String value)
Output only. The name of service revision.
string revision = 18 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameter | |
---|---|
Name | Description |
value | String The revision to set. |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
setRevisionBytes(ByteString value)
public ServiceConfig.Builder setRevisionBytes(ByteString value)
Output only. The name of service revision.
string revision = 18 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameter | |
---|---|
Name | Description |
value | ByteString The bytes for revision to set. |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
setSecretEnvironmentVariables(int index, SecretEnvVar value)
public ServiceConfig.Builder setSecretEnvironmentVariables(int index, SecretEnvVar value)
Secret environment variables configuration.
repeated .google.cloud.functions.v2.SecretEnvVar secret_environment_variables = 17;
Parameters | |
---|---|
Name | Description |
index | int |
value | SecretEnvVar |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder |
setSecretEnvironmentVariables(int index, SecretEnvVar.Builder builderForValue)
public ServiceConfig.Builder setSecretEnvironmentVariables(int index, SecretEnvVar.Builder builderForValue)
Secret environment variables configuration.
repeated .google.cloud.functions.v2.SecretEnvVar secret_environment_variables = 17;
Parameters | |
---|---|
Name | Description |
index | int |
builderForValue | SecretEnvVar.Builder |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder |
setSecretVolumes(int index, SecretVolume value)
public ServiceConfig.Builder setSecretVolumes(int index, SecretVolume value)
Secret volumes configuration.
repeated .google.cloud.functions.v2.SecretVolume secret_volumes = 19;
Parameters | |
---|---|
Name | Description |
index | int |
value | SecretVolume |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder |
setSecretVolumes(int index, SecretVolume.Builder builderForValue)
public ServiceConfig.Builder setSecretVolumes(int index, SecretVolume.Builder builderForValue)
Secret volumes configuration.
repeated .google.cloud.functions.v2.SecretVolume secret_volumes = 19;
Parameters | |
---|---|
Name | Description |
index | int |
builderForValue | SecretVolume.Builder |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder |
setSecurityLevel(ServiceConfig.SecurityLevel value)
public ServiceConfig.Builder setSecurityLevel(ServiceConfig.SecurityLevel value)
Security level configure whether the function only accepts https. This configuration is only applicable to 1st Gen functions with Http trigger. By default https is optional for 1st Gen functions; 2nd Gen functions are https ONLY.
.google.cloud.functions.v2.ServiceConfig.SecurityLevel security_level = 21;
Parameter | |
---|---|
Name | Description |
value | ServiceConfig.SecurityLevel The securityLevel to set. |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
setSecurityLevelValue(int value)
public ServiceConfig.Builder setSecurityLevelValue(int value)
Security level configure whether the function only accepts https. This configuration is only applicable to 1st Gen functions with Http trigger. By default https is optional for 1st Gen functions; 2nd Gen functions are https ONLY.
.google.cloud.functions.v2.ServiceConfig.SecurityLevel security_level = 21;
Parameter | |
---|---|
Name | Description |
value | int The enum numeric value on the wire for securityLevel to set. |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
setService(String value)
public ServiceConfig.Builder setService(String value)
Output only. Name of the service associated with a Function.
The format of this field is
projects/{project}/locations/{region}/services/{service}
string service = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... }
Parameter | |
---|---|
Name | Description |
value | String The service to set. |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
setServiceAccountEmail(String value)
public ServiceConfig.Builder setServiceAccountEmail(String value)
The email of the service's service account. If empty, defaults to
{project_number}-compute@developer.gserviceaccount.com
.
string service_account_email = 10;
Parameter | |
---|---|
Name | Description |
value | String The serviceAccountEmail to set. |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
setServiceAccountEmailBytes(ByteString value)
public ServiceConfig.Builder setServiceAccountEmailBytes(ByteString value)
The email of the service's service account. If empty, defaults to
{project_number}-compute@developer.gserviceaccount.com
.
string service_account_email = 10;
Parameter | |
---|---|
Name | Description |
value | ByteString The bytes for serviceAccountEmail to set. |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
setServiceBytes(ByteString value)
public ServiceConfig.Builder setServiceBytes(ByteString value)
Output only. Name of the service associated with a Function.
The format of this field is
projects/{project}/locations/{region}/services/{service}
string service = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... }
Parameter | |
---|---|
Name | Description |
value | ByteString The bytes for service to set. |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
setTimeoutSeconds(int value)
public ServiceConfig.Builder setTimeoutSeconds(int value)
The function execution timeout. Execution is considered failed and can be terminated if the function is not completed at the end of the timeout period. Defaults to 60 seconds.
int32 timeout_seconds = 2;
Parameter | |
---|---|
Name | Description |
value | int The timeoutSeconds to set. |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
setUnknownFields(UnknownFieldSet unknownFields)
public final ServiceConfig.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter | |
---|---|
Name | Description |
unknownFields | UnknownFieldSet |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder |
setUri(String value)
public ServiceConfig.Builder setUri(String value)
Output only. URI of the Service deployed.
string uri = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameter | |
---|---|
Name | Description |
value | String The uri to set. |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
setUriBytes(ByteString value)
public ServiceConfig.Builder setUriBytes(ByteString value)
Output only. URI of the Service deployed.
string uri = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameter | |
---|---|
Name | Description |
value | ByteString The bytes for uri to set. |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
setVpcConnector(String value)
public ServiceConfig.Builder setVpcConnector(String value)
The Serverless VPC Access connector that this cloud function can connect
to. The format of this field is projects/*/locations/*/connectors/*
.
string vpc_connector = 6 [(.google.api.resource_reference) = { ... }
Parameter | |
---|---|
Name | Description |
value | String The vpcConnector to set. |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
setVpcConnectorBytes(ByteString value)
public ServiceConfig.Builder setVpcConnectorBytes(ByteString value)
The Serverless VPC Access connector that this cloud function can connect
to. The format of this field is projects/*/locations/*/connectors/*
.
string vpc_connector = 6 [(.google.api.resource_reference) = { ... }
Parameter | |
---|---|
Name | Description |
value | ByteString The bytes for vpcConnector to set. |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
setVpcConnectorEgressSettings(ServiceConfig.VpcConnectorEgressSettings value)
public ServiceConfig.Builder setVpcConnectorEgressSettings(ServiceConfig.VpcConnectorEgressSettings value)
The egress settings for the connector, controlling what traffic is diverted through it.
.google.cloud.functions.v2.ServiceConfig.VpcConnectorEgressSettings vpc_connector_egress_settings = 7;
Parameter | |
---|---|
Name | Description |
value | ServiceConfig.VpcConnectorEgressSettings The vpcConnectorEgressSettings to set. |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |
setVpcConnectorEgressSettingsValue(int value)
public ServiceConfig.Builder setVpcConnectorEgressSettingsValue(int value)
The egress settings for the connector, controlling what traffic is diverted through it.
.google.cloud.functions.v2.ServiceConfig.VpcConnectorEgressSettings vpc_connector_egress_settings = 7;
Parameter | |
---|---|
Name | Description |
value | int The enum numeric value on the wire for vpcConnectorEgressSettings to set. |
Returns | |
---|---|
Type | Description |
ServiceConfig.Builder | This builder for chaining. |