Class AppProfile.SingleClusterRoutingPolicy
java.lang.Object
com.google.cloud.bigtable.admin.v2.models.AppProfile.SingleClusterRoutingPolicy
- All Implemented Interfaces:
AppProfile.RoutingPolicy
- Enclosing class:
- AppProfile
public static class AppProfile.SingleClusterRoutingPolicy
extends Object
implements AppProfile.RoutingPolicy
A
AppProfile.RoutingPolicy
that routes all requests to a specific cluster.-
Method Summary
Modifier and TypeMethodDescriptionboolean
fromProto
(com.google.bigtable.admin.v2.AppProfile.SingleClusterRouting proto) Wraps a protobuf response.boolean
Checks if transactional writes are enabled.Gets the target cluster of this policy.int
hashCode()
Builds a new instance of the routing policy that will send all requests to the specified cluster.Builds a new instance of the routing policy that will send all requests to the specified cluster.
-
Method Details
-
fromProto
@InternalApi public static AppProfile.SingleClusterRoutingPolicy fromProto(com.google.bigtable.admin.v2.AppProfile.SingleClusterRouting proto) Wraps a protobuf response.This method is considered an internal implementation detail and not meant to be used by applications.
-
of
Builds a new instance of the routing policy that will send all requests to the specified cluster.Please note that atomic row transactions will be disabled.
-
of
public static AppProfile.SingleClusterRoutingPolicy of(String clusterId, boolean allowTransactionWrites) Builds a new instance of the routing policy that will send all requests to the specified cluster. This variant enables the ability to re-enable single row transactions at the cost of consistency.Please see the online documentation for more details.
-
getClusterId
Gets the target cluster of this policy. -
getAllowTransactionalWrites
public boolean getAllowTransactionalWrites()Checks if transactional writes are enabled. -
equals
-
hashCode
public int hashCode()
-