Class CloudRunV2ServiceTraffic.Builder
- java.lang.Object
-
- com.hashicorp.cdktf.providers.google.cloud_run_v2_service.CloudRunV2ServiceTraffic.Builder
-
- All Implemented Interfaces:
software.amazon.jsii.Builder<CloudRunV2ServiceTraffic>
- Enclosing interface:
- CloudRunV2ServiceTraffic
@Stability(Stable) public static final class CloudRunV2ServiceTraffic.Builder extends Object implements software.amazon.jsii.Builder<CloudRunV2ServiceTraffic>
A builder forCloudRunV2ServiceTraffic
-
-
Constructor Summary
Constructors Constructor Description Builder()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description CloudRunV2ServiceTrafficbuild()Builds the configured instance.CloudRunV2ServiceTraffic.Builderpercent(Number percent)Sets the value ofCloudRunV2ServiceTraffic.getPercent()CloudRunV2ServiceTraffic.Builderrevision(String revision)Sets the value ofCloudRunV2ServiceTraffic.getRevision()CloudRunV2ServiceTraffic.Buildertag(String tag)Sets the value ofCloudRunV2ServiceTraffic.getTag()CloudRunV2ServiceTraffic.Buildertype(String type)Sets the value ofCloudRunV2ServiceTraffic.getType()
-
-
-
Method Detail
-
percent
@Stability(Stable) public CloudRunV2ServiceTraffic.Builder percent(Number percent)
Sets the value ofCloudRunV2ServiceTraffic.getPercent()- Parameters:
percent- Specifies percent of the traffic to this Revision. This defaults to zero if unspecified. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/cloud_run_v2_service#percent CloudRunV2Service#percent}- Returns:
this
-
revision
@Stability(Stable) public CloudRunV2ServiceTraffic.Builder revision(String revision)
Sets the value ofCloudRunV2ServiceTraffic.getRevision()- Parameters:
revision- Revision to which to send this portion of traffic, if traffic allocation is by revision. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/cloud_run_v2_service#revision CloudRunV2Service#revision}- Returns:
this
-
tag
@Stability(Stable) public CloudRunV2ServiceTraffic.Builder tag(String tag)
Sets the value ofCloudRunV2ServiceTraffic.getTag()- Parameters:
tag- Indicates a string to be part of the URI to exclusively reference this target. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/cloud_run_v2_service#tag CloudRunV2Service#tag}- Returns:
this
-
type
@Stability(Stable) public CloudRunV2ServiceTraffic.Builder type(String type)
Sets the value ofCloudRunV2ServiceTraffic.getType()- Parameters:
type- The allocation type for this traffic target. Possible values: ["TRAFFIC_TARGET_ALLOCATION_TYPE_LATEST", "TRAFFIC_TARGET_ALLOCATION_TYPE_REVISION"]. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/cloud_run_v2_service#type CloudRunV2Service#type}- Returns:
this
-
build
@Stability(Stable) public CloudRunV2ServiceTraffic build()
Builds the configured instance.- Specified by:
buildin interfacesoftware.amazon.jsii.Builder<CloudRunV2ServiceTraffic>- Returns:
- a new instance of
CloudRunV2ServiceTraffic - Throws:
NullPointerException- if any required attribute was not provided
-
-