Class BackendServiceConnectionTrackingPolicy (1.54.0)

public final class BackendServiceConnectionTrackingPolicy extends GeneratedMessageV3 implements BackendServiceConnectionTrackingPolicyOrBuilder

Connection Tracking configuration for this BackendService.

Protobuf type google.cloud.compute.v1.BackendServiceConnectionTrackingPolicy

Inheritance

Object > AbstractMessageLite<MessageType,BuilderType> > AbstractMessage > GeneratedMessageV3 > BackendServiceConnectionTrackingPolicy

Static Fields

CONNECTION_PERSISTENCE_ON_UNHEALTHY_BACKENDS_FIELD_NUMBER

public static final int CONNECTION_PERSISTENCE_ON_UNHEALTHY_BACKENDS_FIELD_NUMBER
Field Value
Type Description
int

ENABLE_STRONG_AFFINITY_FIELD_NUMBER

public static final int ENABLE_STRONG_AFFINITY_FIELD_NUMBER
Field Value
Type Description
int

IDLE_TIMEOUT_SEC_FIELD_NUMBER

public static final int IDLE_TIMEOUT_SEC_FIELD_NUMBER
Field Value
Type Description
int

TRACKING_MODE_FIELD_NUMBER

public static final int TRACKING_MODE_FIELD_NUMBER
Field Value
Type Description
int

Static Methods

getDefaultInstance()

public static BackendServiceConnectionTrackingPolicy getDefaultInstance()
Returns
Type Description
BackendServiceConnectionTrackingPolicy

getDescriptor()

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

newBuilder()

public static BackendServiceConnectionTrackingPolicy.Builder newBuilder()
Returns
Type Description
BackendServiceConnectionTrackingPolicy.Builder

newBuilder(BackendServiceConnectionTrackingPolicy prototype)

public static BackendServiceConnectionTrackingPolicy.Builder newBuilder(BackendServiceConnectionTrackingPolicy prototype)
Parameter
Name Description
prototype BackendServiceConnectionTrackingPolicy
Returns
Type Description
BackendServiceConnectionTrackingPolicy.Builder

parseDelimitedFrom(InputStream input)

public static BackendServiceConnectionTrackingPolicy parseDelimitedFrom(InputStream input)
Parameter
Name Description
input InputStream
Returns
Type Description
BackendServiceConnectionTrackingPolicy
Exceptions
Type Description
IOException

parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static BackendServiceConnectionTrackingPolicy parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input InputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
BackendServiceConnectionTrackingPolicy
Exceptions
Type Description
IOException

parseFrom(byte[] data)

public static BackendServiceConnectionTrackingPolicy parseFrom(byte[] data)
Parameter
Name Description
data byte[]
Returns
Type Description
BackendServiceConnectionTrackingPolicy
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)

public static BackendServiceConnectionTrackingPolicy parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
data byte[]
extensionRegistry ExtensionRegistryLite
Returns
Type Description
BackendServiceConnectionTrackingPolicy
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(ByteString data)

public static BackendServiceConnectionTrackingPolicy parseFrom(ByteString data)
Parameter
Name Description
data ByteString
Returns
Type Description
BackendServiceConnectionTrackingPolicy
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)

public static BackendServiceConnectionTrackingPolicy parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
data ByteString
extensionRegistry ExtensionRegistryLite
Returns
Type Description
BackendServiceConnectionTrackingPolicy
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(CodedInputStream input)

public static BackendServiceConnectionTrackingPolicy parseFrom(CodedInputStream input)
Parameter
Name Description
input CodedInputStream
Returns
Type Description
BackendServiceConnectionTrackingPolicy
Exceptions
Type Description
IOException

parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public static BackendServiceConnectionTrackingPolicy parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
BackendServiceConnectionTrackingPolicy
Exceptions
Type Description
IOException

parseFrom(InputStream input)

public static BackendServiceConnectionTrackingPolicy parseFrom(InputStream input)
Parameter
Name Description
input InputStream
Returns
Type Description
BackendServiceConnectionTrackingPolicy
Exceptions
Type Description
IOException

parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static BackendServiceConnectionTrackingPolicy parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input InputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
BackendServiceConnectionTrackingPolicy
Exceptions
Type Description
IOException

parseFrom(ByteBuffer data)

public static BackendServiceConnectionTrackingPolicy parseFrom(ByteBuffer data)
Parameter
Name Description
data ByteBuffer
Returns
Type Description
BackendServiceConnectionTrackingPolicy
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)

public static BackendServiceConnectionTrackingPolicy parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
data ByteBuffer
extensionRegistry ExtensionRegistryLite
Returns
Type Description
BackendServiceConnectionTrackingPolicy
Exceptions
Type Description
InvalidProtocolBufferException

parser()

public static Parser<BackendServiceConnectionTrackingPolicy> parser()
Returns
Type Description
Parser<BackendServiceConnectionTrackingPolicy>

Methods

equals(Object obj)

public boolean equals(Object obj)
Parameter
Name Description
obj Object
Returns
Type Description
boolean
Overrides

getConnectionPersistenceOnUnhealthyBackends()

public String getConnectionPersistenceOnUnhealthyBackends()

Specifies connection persistence when backends are unhealthy. The default value is DEFAULT_FOR_PROTOCOL. If set to DEFAULT_FOR_PROTOCOL, the existing connections persist on unhealthy backends only for connection-oriented protocols (TCP and SCTP) and only if the Tracking Mode is PER_CONNECTION (default tracking mode) or the Session Affinity is configured for 5-tuple. They do not persist for UDP. If set to NEVER_PERSIST, after a backend becomes unhealthy, the existing connections on the unhealthy backend are never persisted on the unhealthy backend. They are always diverted to newly selected healthy backends (unless all backends are unhealthy). If set to ALWAYS_PERSIST, existing connections always persist on unhealthy backends regardless of protocol and session affinity. It is generally not recommended to use this mode overriding the default. For more details, see Connection Persistence for Network Load Balancing and Connection Persistence for Internal TCP/UDP Load Balancing. Check the ConnectionPersistenceOnUnhealthyBackends enum for the list of possible values.

optional string connection_persistence_on_unhealthy_backends = 152439033;

Returns
Type Description
String

The connectionPersistenceOnUnhealthyBackends.

getConnectionPersistenceOnUnhealthyBackendsBytes()

public ByteString getConnectionPersistenceOnUnhealthyBackendsBytes()

Specifies connection persistence when backends are unhealthy. The default value is DEFAULT_FOR_PROTOCOL. If set to DEFAULT_FOR_PROTOCOL, the existing connections persist on unhealthy backends only for connection-oriented protocols (TCP and SCTP) and only if the Tracking Mode is PER_CONNECTION (default tracking mode) or the Session Affinity is configured for 5-tuple. They do not persist for UDP. If set to NEVER_PERSIST, after a backend becomes unhealthy, the existing connections on the unhealthy backend are never persisted on the unhealthy backend. They are always diverted to newly selected healthy backends (unless all backends are unhealthy). If set to ALWAYS_PERSIST, existing connections always persist on unhealthy backends regardless of protocol and session affinity. It is generally not recommended to use this mode overriding the default. For more details, see Connection Persistence for Network Load Balancing and Connection Persistence for Internal TCP/UDP Load Balancing. Check the ConnectionPersistenceOnUnhealthyBackends enum for the list of possible values.

optional string connection_persistence_on_unhealthy_backends = 152439033;

Returns
Type Description
ByteString

The bytes for connectionPersistenceOnUnhealthyBackends.

getDefaultInstanceForType()

public BackendServiceConnectionTrackingPolicy getDefaultInstanceForType()
Returns
Type Description
BackendServiceConnectionTrackingPolicy

getEnableStrongAffinity()

public boolean getEnableStrongAffinity()

Enable Strong Session Affinity for external passthrough Network Load Balancers. This option is not available publicly.

optional bool enable_strong_affinity = 24539924;

Returns
Type Description
boolean

The enableStrongAffinity.

getIdleTimeoutSec()

public int getIdleTimeoutSec()

Specifies how long to keep a Connection Tracking entry while there is no matching traffic (in seconds). For internal passthrough Network Load Balancers: - The minimum (default) is 10 minutes and the maximum is 16 hours. - It can be set only if Connection Tracking is less than 5-tuple (i.e. Session Affinity is CLIENT_IP_NO_DESTINATION, CLIENT_IP or CLIENT_IP_PROTO, and Tracking Mode is PER_SESSION). For external passthrough Network Load Balancers the default is 60 seconds. This option is not available publicly.

optional int32 idle_timeout_sec = 24977544;

Returns
Type Description
int

The idleTimeoutSec.

getParserForType()

public Parser<BackendServiceConnectionTrackingPolicy> getParserForType()
Returns
Type Description
Parser<BackendServiceConnectionTrackingPolicy>
Overrides

getSerializedSize()

public int getSerializedSize()
Returns
Type Description
int
Overrides

getTrackingMode()

public String getTrackingMode()

Specifies the key used for connection tracking. There are two options: - PER_CONNECTION: This is the default mode. The Connection Tracking is performed as per the Connection Key (default Hash Method) for the specific protocol. - PER_SESSION: The Connection Tracking is performed as per the configured Session Affinity. It matches the configured Session Affinity. For more details, see Tracking Mode for Network Load Balancing and Tracking Mode for Internal TCP/UDP Load Balancing. Check the TrackingMode enum for the list of possible values.

optional string tracking_mode = 127757867;

Returns
Type Description
String

The trackingMode.

getTrackingModeBytes()

public ByteString getTrackingModeBytes()

Specifies the key used for connection tracking. There are two options: - PER_CONNECTION: This is the default mode. The Connection Tracking is performed as per the Connection Key (default Hash Method) for the specific protocol. - PER_SESSION: The Connection Tracking is performed as per the configured Session Affinity. It matches the configured Session Affinity. For more details, see Tracking Mode for Network Load Balancing and Tracking Mode for Internal TCP/UDP Load Balancing. Check the TrackingMode enum for the list of possible values.

optional string tracking_mode = 127757867;

Returns
Type Description
ByteString

The bytes for trackingMode.

hasConnectionPersistenceOnUnhealthyBackends()

public boolean hasConnectionPersistenceOnUnhealthyBackends()

Specifies connection persistence when backends are unhealthy. The default value is DEFAULT_FOR_PROTOCOL. If set to DEFAULT_FOR_PROTOCOL, the existing connections persist on unhealthy backends only for connection-oriented protocols (TCP and SCTP) and only if the Tracking Mode is PER_CONNECTION (default tracking mode) or the Session Affinity is configured for 5-tuple. They do not persist for UDP. If set to NEVER_PERSIST, after a backend becomes unhealthy, the existing connections on the unhealthy backend are never persisted on the unhealthy backend. They are always diverted to newly selected healthy backends (unless all backends are unhealthy). If set to ALWAYS_PERSIST, existing connections always persist on unhealthy backends regardless of protocol and session affinity. It is generally not recommended to use this mode overriding the default. For more details, see Connection Persistence for Network Load Balancing and Connection Persistence for Internal TCP/UDP Load Balancing. Check the ConnectionPersistenceOnUnhealthyBackends enum for the list of possible values.

optional string connection_persistence_on_unhealthy_backends = 152439033;

Returns
Type Description
boolean

Whether the connectionPersistenceOnUnhealthyBackends field is set.

hasEnableStrongAffinity()

public boolean hasEnableStrongAffinity()

Enable Strong Session Affinity for external passthrough Network Load Balancers. This option is not available publicly.

optional bool enable_strong_affinity = 24539924;

Returns
Type Description
boolean

Whether the enableStrongAffinity field is set.

hasIdleTimeoutSec()

public boolean hasIdleTimeoutSec()

Specifies how long to keep a Connection Tracking entry while there is no matching traffic (in seconds). For internal passthrough Network Load Balancers: - The minimum (default) is 10 minutes and the maximum is 16 hours. - It can be set only if Connection Tracking is less than 5-tuple (i.e. Session Affinity is CLIENT_IP_NO_DESTINATION, CLIENT_IP or CLIENT_IP_PROTO, and Tracking Mode is PER_SESSION). For external passthrough Network Load Balancers the default is 60 seconds. This option is not available publicly.

optional int32 idle_timeout_sec = 24977544;

Returns
Type Description
boolean

Whether the idleTimeoutSec field is set.

hasTrackingMode()

public boolean hasTrackingMode()

Specifies the key used for connection tracking. There are two options: - PER_CONNECTION: This is the default mode. The Connection Tracking is performed as per the Connection Key (default Hash Method) for the specific protocol. - PER_SESSION: The Connection Tracking is performed as per the configured Session Affinity. It matches the configured Session Affinity. For more details, see Tracking Mode for Network Load Balancing and Tracking Mode for Internal TCP/UDP Load Balancing. Check the TrackingMode enum for the list of possible values.

optional string tracking_mode = 127757867;

Returns
Type Description
boolean

Whether the trackingMode field is set.

hashCode()

public int hashCode()
Returns
Type Description
int
Overrides

internalGetFieldAccessorTable()

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

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

newBuilderForType()

public BackendServiceConnectionTrackingPolicy.Builder newBuilderForType()
Returns
Type Description
BackendServiceConnectionTrackingPolicy.Builder

newBuilderForType(GeneratedMessageV3.BuilderParent parent)

protected BackendServiceConnectionTrackingPolicy.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Parameter
Name Description
parent BuilderParent
Returns
Type Description
BackendServiceConnectionTrackingPolicy.Builder
Overrides

newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)

protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Parameter
Name Description
unused UnusedPrivateParameter
Returns
Type Description
Object
Overrides

toBuilder()

public BackendServiceConnectionTrackingPolicy.Builder toBuilder()
Returns
Type Description
BackendServiceConnectionTrackingPolicy.Builder

writeTo(CodedOutputStream output)

public void writeTo(CodedOutputStream output)
Parameter
Name Description
output CodedOutputStream
Overrides
Exceptions
Type Description
IOException