public static class AppProfile.SingleClusterRoutingPolicy extends Object implements AppProfile.RoutingPolicy
AppProfile.RoutingPolicy
that routes all requests to a specific cluster.Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object o) |
static AppProfile.SingleClusterRoutingPolicy |
fromProto(AppProfile.SingleClusterRouting proto)
Wraps a protobuf response.
|
boolean |
getAllowTransactionalWrites()
Checks if transactional writes are enabled.
|
String |
getClusterId()
Gets the target cluster of this policy.
|
int |
hashCode() |
static AppProfile.SingleClusterRoutingPolicy |
of(String clusterId)
Builds a new instance of the routing policy that will send all requests to the specified
cluster.
|
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.
|
@InternalApi public static AppProfile.SingleClusterRoutingPolicy fromProto(AppProfile.SingleClusterRouting proto)
This method is considered an internal implementation detail and not meant to be used by applications.
public static AppProfile.SingleClusterRoutingPolicy of(String clusterId)
Please note that atomic row transactions will be disabled.
public static AppProfile.SingleClusterRoutingPolicy of(String clusterId, boolean allowTransactionWrites)
Please see the online documentation for more details.
public String getClusterId()
public boolean getAllowTransactionalWrites()
Copyright © 2019 Google LLC. All rights reserved.