public final class TrafficSplit extends GeneratedMessageV3 implements TrafficSplitOrBuilder
Traffic routing configuration for versions within a single service. Traffic
splits define how traffic directed to the service is assigned to versions.
Protobuf type google.appengine.v1.TrafficSplit
Static Fields
ALLOCATIONS_FIELD_NUMBER
public static final int ALLOCATIONS_FIELD_NUMBER
Field Value
SHARD_BY_FIELD_NUMBER
public static final int SHARD_BY_FIELD_NUMBER
Field Value
Static Methods
getDefaultInstance()
public static TrafficSplit getDefaultInstance()
Returns
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
Returns
newBuilder()
public static TrafficSplit.Builder newBuilder()
Returns
newBuilder(TrafficSplit prototype)
public static TrafficSplit.Builder newBuilder(TrafficSplit prototype)
Parameter
Returns
public static TrafficSplit parseDelimitedFrom(InputStream input)
Parameter
Returns
Exceptions
public static TrafficSplit parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
parseFrom(byte[] data)
public static TrafficSplit parseFrom(byte[] data)
Parameter
Name | Description |
data | byte[]
|
Returns
Exceptions
parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
public static TrafficSplit parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
parseFrom(ByteString data)
public static TrafficSplit parseFrom(ByteString data)
Parameter
Returns
Exceptions
parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
public static TrafficSplit parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
public static TrafficSplit parseFrom(CodedInputStream input)
Parameter
Returns
Exceptions
public static TrafficSplit parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
public static TrafficSplit parseFrom(InputStream input)
Parameter
Returns
Exceptions
public static TrafficSplit parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
parseFrom(ByteBuffer data)
public static TrafficSplit parseFrom(ByteBuffer data)
Parameter
Returns
Exceptions
parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
public static TrafficSplit parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
parser()
public static Parser<TrafficSplit> parser()
Returns
Methods
containsAllocations(String key)
public boolean containsAllocations(String key)
Mapping from version IDs within the service to fractional
(0.000, 1] allocations of traffic for that version. Each version can
be specified only once, but some versions in the service may not
have any traffic allocation. Services that have traffic allocated
cannot be deleted until either the service is deleted or
their traffic allocation is removed. Allocations must sum to 1.
Up to two decimal place precision is supported for IP-based splits and
up to three decimal places is supported for cookie-based splits.
map<string, double> allocations = 2;
Parameter
Returns
equals(Object obj)
public boolean equals(Object obj)
Parameter
Returns
Overrides
getAllocations()
public Map<String,Double> getAllocations()
Returns
getAllocationsCount()
public int getAllocationsCount()
Mapping from version IDs within the service to fractional
(0.000, 1] allocations of traffic for that version. Each version can
be specified only once, but some versions in the service may not
have any traffic allocation. Services that have traffic allocated
cannot be deleted until either the service is deleted or
their traffic allocation is removed. Allocations must sum to 1.
Up to two decimal place precision is supported for IP-based splits and
up to three decimal places is supported for cookie-based splits.
map<string, double> allocations = 2;
Returns
getAllocationsMap()
public Map<String,Double> getAllocationsMap()
Mapping from version IDs within the service to fractional
(0.000, 1] allocations of traffic for that version. Each version can
be specified only once, but some versions in the service may not
have any traffic allocation. Services that have traffic allocated
cannot be deleted until either the service is deleted or
their traffic allocation is removed. Allocations must sum to 1.
Up to two decimal place precision is supported for IP-based splits and
up to three decimal places is supported for cookie-based splits.
map<string, double> allocations = 2;
Returns
getAllocationsOrDefault(String key, double defaultValue)
public double getAllocationsOrDefault(String key, double defaultValue)
Mapping from version IDs within the service to fractional
(0.000, 1] allocations of traffic for that version. Each version can
be specified only once, but some versions in the service may not
have any traffic allocation. Services that have traffic allocated
cannot be deleted until either the service is deleted or
their traffic allocation is removed. Allocations must sum to 1.
Up to two decimal place precision is supported for IP-based splits and
up to three decimal places is supported for cookie-based splits.
map<string, double> allocations = 2;
Parameters
Returns
getAllocationsOrThrow(String key)
public double getAllocationsOrThrow(String key)
Mapping from version IDs within the service to fractional
(0.000, 1] allocations of traffic for that version. Each version can
be specified only once, but some versions in the service may not
have any traffic allocation. Services that have traffic allocated
cannot be deleted until either the service is deleted or
their traffic allocation is removed. Allocations must sum to 1.
Up to two decimal place precision is supported for IP-based splits and
up to three decimal places is supported for cookie-based splits.
map<string, double> allocations = 2;
Parameter
Returns
getDefaultInstanceForType()
public TrafficSplit getDefaultInstanceForType()
Returns
getParserForType()
public Parser<TrafficSplit> getParserForType()
Returns
Overrides
getSerializedSize()
public int getSerializedSize()
Returns
Overrides
getShardBy()
public TrafficSplit.ShardBy getShardBy()
Mechanism used to determine which version a request is sent to.
The traffic selection algorithm will
be stable for either type until allocations are changed.
.google.appengine.v1.TrafficSplit.ShardBy shard_by = 1;
Returns
getShardByValue()
public int getShardByValue()
Mechanism used to determine which version a request is sent to.
The traffic selection algorithm will
be stable for either type until allocations are changed.
.google.appengine.v1.TrafficSplit.ShardBy shard_by = 1;
Returns
Type | Description |
int | The enum numeric value on the wire for shardBy.
|
getUnknownFields()
public final UnknownFieldSet getUnknownFields()
Returns
Overrides
hashCode()
Returns
Overrides
internalGetFieldAccessorTable()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Overrides
internalGetMapField(int number)
protected MapField internalGetMapField(int number)
Parameter
Returns
Overrides
isInitialized()
public final boolean isInitialized()
Returns
Overrides
newBuilderForType()
public TrafficSplit.Builder newBuilderForType()
Returns
newBuilderForType(GeneratedMessageV3.BuilderParent parent)
protected TrafficSplit.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Parameter
Returns
Overrides
newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Parameter
Returns
Overrides
toBuilder()
public TrafficSplit.Builder toBuilder()
Returns
writeTo(CodedOutputStream output)
public void writeTo(CodedOutputStream output)
Parameter
Overrides
Exceptions