Class ServiceScaling.Builder (0.54.0)

public static final class ServiceScaling.Builder extends GeneratedMessageV3.Builder<ServiceScaling.Builder> implements ServiceScalingOrBuilder

Scaling settings applied at the service level rather than at the revision level.

Protobuf type google.cloud.run.v2.ServiceScaling

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
Type Description
Descriptor

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public ServiceScaling.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
ServiceScaling.Builder
Overrides

build()

public ServiceScaling build()
Returns
Type Description
ServiceScaling

buildPartial()

public ServiceScaling buildPartial()
Returns
Type Description
ServiceScaling

clear()

public ServiceScaling.Builder clear()
Returns
Type Description
ServiceScaling.Builder
Overrides

clearField(Descriptors.FieldDescriptor field)

public ServiceScaling.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Name Description
field FieldDescriptor
Returns
Type Description
ServiceScaling.Builder
Overrides

clearMinInstanceCount()

public ServiceScaling.Builder clearMinInstanceCount()

Optional. total min instances for the service. This number of instances is divided among all revisions with specified traffic based on the percent of traffic they are receiving.

int32 min_instance_count = 1 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
ServiceScaling.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

public ServiceScaling.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Name Description
oneof OneofDescriptor
Returns
Type Description
ServiceScaling.Builder
Overrides

clearScalingMode()

public ServiceScaling.Builder clearScalingMode()

Optional. The scaling mode for the service.

.google.cloud.run.v2.ServiceScaling.ScalingMode scaling_mode = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
ServiceScaling.Builder

This builder for chaining.

clone()

public ServiceScaling.Builder clone()
Returns
Type Description
ServiceScaling.Builder
Overrides

getDefaultInstanceForType()

public ServiceScaling getDefaultInstanceForType()
Returns
Type Description
ServiceScaling

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
Type Description
Descriptor
Overrides

getMinInstanceCount()

public int getMinInstanceCount()

Optional. total min instances for the service. This number of instances is divided among all revisions with specified traffic based on the percent of traffic they are receiving.

int32 min_instance_count = 1 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
int

The minInstanceCount.

getScalingMode()

public ServiceScaling.ScalingMode getScalingMode()

Optional. The scaling mode for the service.

.google.cloud.run.v2.ServiceScaling.ScalingMode scaling_mode = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
ServiceScaling.ScalingMode

The scalingMode.

getScalingModeValue()

public int getScalingModeValue()

Optional. The scaling mode for the service.

.google.cloud.run.v2.ServiceScaling.ScalingMode scaling_mode = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
int

The enum numeric value on the wire for scalingMode.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Type Description
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(ServiceScaling other)

public ServiceScaling.Builder mergeFrom(ServiceScaling other)
Parameter
Name Description
other ServiceScaling
Returns
Type Description
ServiceScaling.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public ServiceScaling.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
ServiceScaling.Builder
Overrides
Exceptions
Type Description
IOException

mergeFrom(Message other)

public ServiceScaling.Builder mergeFrom(Message other)
Parameter
Name Description
other Message
Returns
Type Description
ServiceScaling.Builder
Overrides

mergeUnknownFields(UnknownFieldSet unknownFields)

public final ServiceScaling.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
ServiceScaling.Builder
Overrides

setField(Descriptors.FieldDescriptor field, Object value)

public ServiceScaling.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
ServiceScaling.Builder
Overrides

setMinInstanceCount(int value)

public ServiceScaling.Builder setMinInstanceCount(int value)

Optional. total min instances for the service. This number of instances is divided among all revisions with specified traffic based on the percent of traffic they are receiving.

int32 min_instance_count = 1 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value int

The minInstanceCount to set.

Returns
Type Description
ServiceScaling.Builder

This builder for chaining.

setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)

public ServiceScaling.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Name Description
field FieldDescriptor
index int
value Object
Returns
Type Description
ServiceScaling.Builder
Overrides

setScalingMode(ServiceScaling.ScalingMode value)

public ServiceScaling.Builder setScalingMode(ServiceScaling.ScalingMode value)

Optional. The scaling mode for the service.

.google.cloud.run.v2.ServiceScaling.ScalingMode scaling_mode = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value ServiceScaling.ScalingMode

The scalingMode to set.

Returns
Type Description
ServiceScaling.Builder

This builder for chaining.

setScalingModeValue(int value)

public ServiceScaling.Builder setScalingModeValue(int value)

Optional. The scaling mode for the service.

.google.cloud.run.v2.ServiceScaling.ScalingMode scaling_mode = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value int

The enum numeric value on the wire for scalingMode to set.

Returns
Type Description
ServiceScaling.Builder

This builder for chaining.

setUnknownFields(UnknownFieldSet unknownFields)

public final ServiceScaling.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
ServiceScaling.Builder
Overrides