public static interface Cluster.LbSubsetConfigOrBuilder
extends com.google.protobuf.MessageOrBuilder
| Modifier and Type | Method and Description |
|---|---|
com.google.protobuf.Struct |
getDefaultSubset()
Specifies the default subset of endpoints used during fallback if
fallback_policy is
:ref:`DEFAULT_SUBSET<envoy_api_enum_value_Cluster.LbSubsetConfig.LbSubsetFallbackPolicy.DEFAULT_SUBSET>`.
|
com.google.protobuf.StructOrBuilder |
getDefaultSubsetOrBuilder()
Specifies the default subset of endpoints used during fallback if
fallback_policy is
:ref:`DEFAULT_SUBSET<envoy_api_enum_value_Cluster.LbSubsetConfig.LbSubsetFallbackPolicy.DEFAULT_SUBSET>`.
|
Cluster.LbSubsetConfig.LbSubsetFallbackPolicy |
getFallbackPolicy()
The behavior used when no endpoint subset matches the selected route's
metadata.
|
int |
getFallbackPolicyValue()
The behavior used when no endpoint subset matches the selected route's
metadata.
|
boolean |
getListAsAny()
If true, metadata specified for a metadata key will be matched against the corresponding
endpoint metadata if the endpoint metadata matches the value exactly OR it is a list value
and any of the elements in the list matches the criteria.
|
boolean |
getLocalityWeightAware()
If true, routing to subsets will take into account the localities and locality weights of the
endpoints when making the routing decision.
|
boolean |
getPanicModeAny()
If true, when a fallback policy is configured and its corresponding subset fails to find
a host this will cause any host to be selected instead.
|
boolean |
getScaleLocalityWeight()
When used with locality_weight_aware, scales the weight of each locality by the ratio
of hosts in the subset vs hosts in the original subset.
|
Cluster.LbSubsetConfig.LbSubsetSelector |
getSubsetSelectors(int index)
For each entry, LbEndpoint.Metadata's
*envoy.lb* namespace is traversed and a subset is created for each unique
combination of key and value.
|
int |
getSubsetSelectorsCount()
For each entry, LbEndpoint.Metadata's
*envoy.lb* namespace is traversed and a subset is created for each unique
combination of key and value.
|
List<Cluster.LbSubsetConfig.LbSubsetSelector> |
getSubsetSelectorsList()
For each entry, LbEndpoint.Metadata's
*envoy.lb* namespace is traversed and a subset is created for each unique
combination of key and value.
|
Cluster.LbSubsetConfig.LbSubsetSelectorOrBuilder |
getSubsetSelectorsOrBuilder(int index)
For each entry, LbEndpoint.Metadata's
*envoy.lb* namespace is traversed and a subset is created for each unique
combination of key and value.
|
List<? extends Cluster.LbSubsetConfig.LbSubsetSelectorOrBuilder> |
getSubsetSelectorsOrBuilderList()
For each entry, LbEndpoint.Metadata's
*envoy.lb* namespace is traversed and a subset is created for each unique
combination of key and value.
|
boolean |
hasDefaultSubset()
Specifies the default subset of endpoints used during fallback if
fallback_policy is
:ref:`DEFAULT_SUBSET<envoy_api_enum_value_Cluster.LbSubsetConfig.LbSubsetFallbackPolicy.DEFAULT_SUBSET>`.
|
findInitializationErrors, getAllFields, getDefaultInstanceForType, getDescriptorForType, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneofint getFallbackPolicyValue()
The behavior used when no endpoint subset matches the selected route's metadata. The value defaults to :ref:`NO_FALLBACK<envoy_api_enum_value_Cluster.LbSubsetConfig.LbSubsetFallbackPolicy.NO_FALLBACK>`.
.envoy.api.v2.Cluster.LbSubsetConfig.LbSubsetFallbackPolicy fallback_policy = 1 [(.validate.rules) = { ... }Cluster.LbSubsetConfig.LbSubsetFallbackPolicy getFallbackPolicy()
The behavior used when no endpoint subset matches the selected route's metadata. The value defaults to :ref:`NO_FALLBACK<envoy_api_enum_value_Cluster.LbSubsetConfig.LbSubsetFallbackPolicy.NO_FALLBACK>`.
.envoy.api.v2.Cluster.LbSubsetConfig.LbSubsetFallbackPolicy fallback_policy = 1 [(.validate.rules) = { ... }boolean hasDefaultSubset()
Specifies the default subset of endpoints used during fallback if fallback_policy is :ref:`DEFAULT_SUBSET<envoy_api_enum_value_Cluster.LbSubsetConfig.LbSubsetFallbackPolicy.DEFAULT_SUBSET>`. Each field in default_subset is compared to the matching LbEndpoint.Metadata under the *envoy.lb* namespace. It is valid for no hosts to match, in which case the behavior is the same as a fallback_policy of :ref:`NO_FALLBACK<envoy_api_enum_value_Cluster.LbSubsetConfig.LbSubsetFallbackPolicy.NO_FALLBACK>`.
.google.protobuf.Struct default_subset = 2;com.google.protobuf.Struct getDefaultSubset()
Specifies the default subset of endpoints used during fallback if fallback_policy is :ref:`DEFAULT_SUBSET<envoy_api_enum_value_Cluster.LbSubsetConfig.LbSubsetFallbackPolicy.DEFAULT_SUBSET>`. Each field in default_subset is compared to the matching LbEndpoint.Metadata under the *envoy.lb* namespace. It is valid for no hosts to match, in which case the behavior is the same as a fallback_policy of :ref:`NO_FALLBACK<envoy_api_enum_value_Cluster.LbSubsetConfig.LbSubsetFallbackPolicy.NO_FALLBACK>`.
.google.protobuf.Struct default_subset = 2;com.google.protobuf.StructOrBuilder getDefaultSubsetOrBuilder()
Specifies the default subset of endpoints used during fallback if fallback_policy is :ref:`DEFAULT_SUBSET<envoy_api_enum_value_Cluster.LbSubsetConfig.LbSubsetFallbackPolicy.DEFAULT_SUBSET>`. Each field in default_subset is compared to the matching LbEndpoint.Metadata under the *envoy.lb* namespace. It is valid for no hosts to match, in which case the behavior is the same as a fallback_policy of :ref:`NO_FALLBACK<envoy_api_enum_value_Cluster.LbSubsetConfig.LbSubsetFallbackPolicy.NO_FALLBACK>`.
.google.protobuf.Struct default_subset = 2;List<Cluster.LbSubsetConfig.LbSubsetSelector> getSubsetSelectorsList()
For each entry, LbEndpoint.Metadata's
*envoy.lb* namespace is traversed and a subset is created for each unique
combination of key and value. For example:
.. code-block:: json
{ "subset_selectors": [
{ "keys": [ "version" ] },
{ "keys": [ "stage", "hardware_type" ] }
]}
A subset is matched when the metadata from the selected route and
weighted cluster contains the same keys and values as the subset's
metadata. The same host may appear in multiple subsets.
repeated .envoy.api.v2.Cluster.LbSubsetConfig.LbSubsetSelector subset_selectors = 3;Cluster.LbSubsetConfig.LbSubsetSelector getSubsetSelectors(int index)
For each entry, LbEndpoint.Metadata's
*envoy.lb* namespace is traversed and a subset is created for each unique
combination of key and value. For example:
.. code-block:: json
{ "subset_selectors": [
{ "keys": [ "version" ] },
{ "keys": [ "stage", "hardware_type" ] }
]}
A subset is matched when the metadata from the selected route and
weighted cluster contains the same keys and values as the subset's
metadata. The same host may appear in multiple subsets.
repeated .envoy.api.v2.Cluster.LbSubsetConfig.LbSubsetSelector subset_selectors = 3;int getSubsetSelectorsCount()
For each entry, LbEndpoint.Metadata's
*envoy.lb* namespace is traversed and a subset is created for each unique
combination of key and value. For example:
.. code-block:: json
{ "subset_selectors": [
{ "keys": [ "version" ] },
{ "keys": [ "stage", "hardware_type" ] }
]}
A subset is matched when the metadata from the selected route and
weighted cluster contains the same keys and values as the subset's
metadata. The same host may appear in multiple subsets.
repeated .envoy.api.v2.Cluster.LbSubsetConfig.LbSubsetSelector subset_selectors = 3;List<? extends Cluster.LbSubsetConfig.LbSubsetSelectorOrBuilder> getSubsetSelectorsOrBuilderList()
For each entry, LbEndpoint.Metadata's
*envoy.lb* namespace is traversed and a subset is created for each unique
combination of key and value. For example:
.. code-block:: json
{ "subset_selectors": [
{ "keys": [ "version" ] },
{ "keys": [ "stage", "hardware_type" ] }
]}
A subset is matched when the metadata from the selected route and
weighted cluster contains the same keys and values as the subset's
metadata. The same host may appear in multiple subsets.
repeated .envoy.api.v2.Cluster.LbSubsetConfig.LbSubsetSelector subset_selectors = 3;Cluster.LbSubsetConfig.LbSubsetSelectorOrBuilder getSubsetSelectorsOrBuilder(int index)
For each entry, LbEndpoint.Metadata's
*envoy.lb* namespace is traversed and a subset is created for each unique
combination of key and value. For example:
.. code-block:: json
{ "subset_selectors": [
{ "keys": [ "version" ] },
{ "keys": [ "stage", "hardware_type" ] }
]}
A subset is matched when the metadata from the selected route and
weighted cluster contains the same keys and values as the subset's
metadata. The same host may appear in multiple subsets.
repeated .envoy.api.v2.Cluster.LbSubsetConfig.LbSubsetSelector subset_selectors = 3;boolean getLocalityWeightAware()
If true, routing to subsets will take into account the localities and locality weights of the endpoints when making the routing decision. There are some potential pitfalls associated with enabling this feature, as the resulting traffic split after applying both a subset match and locality weights might be undesirable. Consider for example a situation in which you have 50/50 split across two localities X/Y which have 100 hosts each without subsetting. If the subset LB results in X having only 1 host selected but Y having 100, then a lot more load is being dumped on the single host in X than originally anticipated in the load balancing assignment delivered via EDS.
bool locality_weight_aware = 4;boolean getScaleLocalityWeight()
When used with locality_weight_aware, scales the weight of each locality by the ratio of hosts in the subset vs hosts in the original subset. This aims to even out the load going to an individual locality if said locality is disproportionately affected by the subset predicate.
bool scale_locality_weight = 5;boolean getPanicModeAny()
If true, when a fallback policy is configured and its corresponding subset fails to find a host this will cause any host to be selected instead. This is useful when using the default subset as the fallback policy, given the default subset might become empty. With this option enabled, if that happens the LB will attempt to select a host from the entire cluster.
bool panic_mode_any = 6;boolean getListAsAny()
If true, metadata specified for a metadata key will be matched against the corresponding endpoint metadata if the endpoint metadata matches the value exactly OR it is a list value and any of the elements in the list matches the criteria.
bool list_as_any = 7;Copyright © 2018–2021 The Envoy Project. All rights reserved.