Class ServiceLbPolicy.AutoCapacityDrain.Builder (0.39.0)

public static final class ServiceLbPolicy.AutoCapacityDrain.Builder extends GeneratedMessage.Builder<ServiceLbPolicy.AutoCapacityDrain.Builder> implements ServiceLbPolicy.AutoCapacityDrainOrBuilder

Option to specify if an unhealthy IG/NEG should be considered for global load balancing and traffic routing.

Protobuf type google.cloud.networkservices.v1.ServiceLbPolicy.AutoCapacityDrain

Static Methods

getDescriptor()

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

Methods

build()

public ServiceLbPolicy.AutoCapacityDrain build()
Returns
Type Description
ServiceLbPolicy.AutoCapacityDrain

buildPartial()

public ServiceLbPolicy.AutoCapacityDrain buildPartial()
Returns
Type Description
ServiceLbPolicy.AutoCapacityDrain

clear()

public ServiceLbPolicy.AutoCapacityDrain.Builder clear()
Returns
Type Description
ServiceLbPolicy.AutoCapacityDrain.Builder
Overrides

clearEnable()

public ServiceLbPolicy.AutoCapacityDrain.Builder clearEnable()

Optional. If set to 'True', an unhealthy IG/NEG will be set as drained.

  • An IG/NEG is considered unhealthy if less than 25% of the instances/endpoints in the IG/NEG are healthy.
  • This option will never result in draining more than 50% of the configured IGs/NEGs for the Backend Service.

bool enable = 1 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
ServiceLbPolicy.AutoCapacityDrain.Builder

This builder for chaining.

getDefaultInstanceForType()

public ServiceLbPolicy.AutoCapacityDrain getDefaultInstanceForType()
Returns
Type Description
ServiceLbPolicy.AutoCapacityDrain

getDescriptorForType()

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

getEnable()

public boolean getEnable()

Optional. If set to 'True', an unhealthy IG/NEG will be set as drained.

  • An IG/NEG is considered unhealthy if less than 25% of the instances/endpoints in the IG/NEG are healthy.
  • This option will never result in draining more than 50% of the configured IGs/NEGs for the Backend Service.

bool enable = 1 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
boolean

The enable.

internalGetFieldAccessorTable()

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

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(ServiceLbPolicy.AutoCapacityDrain other)

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

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

setEnable(boolean value)

public ServiceLbPolicy.AutoCapacityDrain.Builder setEnable(boolean value)

Optional. If set to 'True', an unhealthy IG/NEG will be set as drained.

  • An IG/NEG is considered unhealthy if less than 25% of the instances/endpoints in the IG/NEG are healthy.
  • This option will never result in draining more than 50% of the configured IGs/NEGs for the Backend Service.

bool enable = 1 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value boolean

The enable to set.

Returns
Type Description
ServiceLbPolicy.AutoCapacityDrain.Builder

This builder for chaining.