public static final class VirtualCluster.Builder extends com.google.protobuf.GeneratedMessageV3.Builder<VirtualCluster.Builder> implements VirtualClusterOrBuilder
A virtual cluster is a way of specifying a regex matching rule against
certain important endpoints such that statistics are generated explicitly for
the matched requests. The reason this is useful is that when doing
prefix/path matching Envoy does not always know what the application
considers to be an endpoint. Thus, it’s impossible for Envoy to generically
emit per endpoint statistics. However, often systems have highly critical
endpoints that they wish to get “perfect” statistics on. Virtual cluster
statistics are perfect in the sense that they are emitted on the downstream
side such that they include network level failures.
Documentation for :ref:`virtual cluster statistics <config_http_filters_router_vcluster_stats>`.
.. note::
Virtual clusters are a useful tool, but we do not recommend setting up a virtual cluster for
every application endpoint. This is both not easily maintainable and as well the matching and
statistics output are not free.
Protobuf type envoy.api.v2.route.VirtualCluster| Modifier and Type | Method and Description |
|---|---|
VirtualCluster.Builder |
addAllHeaders(Iterable<? extends HeaderMatcher> values)
Specifies a list of header matchers to use for matching requests.
|
VirtualCluster.Builder |
addHeaders(HeaderMatcher.Builder builderForValue)
Specifies a list of header matchers to use for matching requests.
|
VirtualCluster.Builder |
addHeaders(HeaderMatcher value)
Specifies a list of header matchers to use for matching requests.
|
VirtualCluster.Builder |
addHeaders(int index,
HeaderMatcher.Builder builderForValue)
Specifies a list of header matchers to use for matching requests.
|
VirtualCluster.Builder |
addHeaders(int index,
HeaderMatcher value)
Specifies a list of header matchers to use for matching requests.
|
HeaderMatcher.Builder |
addHeadersBuilder()
Specifies a list of header matchers to use for matching requests.
|
HeaderMatcher.Builder |
addHeadersBuilder(int index)
Specifies a list of header matchers to use for matching requests.
|
VirtualCluster.Builder |
addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field,
Object value) |
VirtualCluster |
build() |
VirtualCluster |
buildPartial() |
VirtualCluster.Builder |
clear() |
VirtualCluster.Builder |
clearField(com.google.protobuf.Descriptors.FieldDescriptor field) |
VirtualCluster.Builder |
clearHeaders()
Specifies a list of header matchers to use for matching requests.
|
VirtualCluster.Builder |
clearMethod()
Deprecated.
|
VirtualCluster.Builder |
clearName()
Specifies the name of the virtual cluster.
|
VirtualCluster.Builder |
clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) |
VirtualCluster.Builder |
clearPattern()
Deprecated.
|
VirtualCluster.Builder |
clone() |
VirtualCluster |
getDefaultInstanceForType() |
static com.google.protobuf.Descriptors.Descriptor |
getDescriptor() |
com.google.protobuf.Descriptors.Descriptor |
getDescriptorForType() |
HeaderMatcher |
getHeaders(int index)
Specifies a list of header matchers to use for matching requests.
|
HeaderMatcher.Builder |
getHeadersBuilder(int index)
Specifies a list of header matchers to use for matching requests.
|
List<HeaderMatcher.Builder> |
getHeadersBuilderList()
Specifies a list of header matchers to use for matching requests.
|
int |
getHeadersCount()
Specifies a list of header matchers to use for matching requests.
|
List<HeaderMatcher> |
getHeadersList()
Specifies a list of header matchers to use for matching requests.
|
HeaderMatcherOrBuilder |
getHeadersOrBuilder(int index)
Specifies a list of header matchers to use for matching requests.
|
List<? extends HeaderMatcherOrBuilder> |
getHeadersOrBuilderList()
Specifies a list of header matchers to use for matching requests.
|
RequestMethod |
getMethod()
Deprecated.
|
int |
getMethodValue()
Deprecated.
|
String |
getName()
Specifies the name of the virtual cluster.
|
com.google.protobuf.ByteString |
getNameBytes()
Specifies the name of the virtual cluster.
|
String |
getPattern()
Deprecated.
|
com.google.protobuf.ByteString |
getPatternBytes()
Deprecated.
|
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable |
internalGetFieldAccessorTable() |
boolean |
isInitialized() |
VirtualCluster.Builder |
mergeFrom(com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
VirtualCluster.Builder |
mergeFrom(com.google.protobuf.Message other) |
VirtualCluster.Builder |
mergeFrom(VirtualCluster other) |
VirtualCluster.Builder |
mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields) |
VirtualCluster.Builder |
removeHeaders(int index)
Specifies a list of header matchers to use for matching requests.
|
VirtualCluster.Builder |
setField(com.google.protobuf.Descriptors.FieldDescriptor field,
Object value) |
VirtualCluster.Builder |
setHeaders(int index,
HeaderMatcher.Builder builderForValue)
Specifies a list of header matchers to use for matching requests.
|
VirtualCluster.Builder |
setHeaders(int index,
HeaderMatcher value)
Specifies a list of header matchers to use for matching requests.
|
VirtualCluster.Builder |
setMethod(RequestMethod value)
Deprecated.
|
VirtualCluster.Builder |
setMethodValue(int value)
Deprecated.
|
VirtualCluster.Builder |
setName(String value)
Specifies the name of the virtual cluster.
|
VirtualCluster.Builder |
setNameBytes(com.google.protobuf.ByteString value)
Specifies the name of the virtual cluster.
|
VirtualCluster.Builder |
setPattern(String value)
Deprecated.
|
VirtualCluster.Builder |
setPatternBytes(com.google.protobuf.ByteString value)
Deprecated.
|
VirtualCluster.Builder |
setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field,
int index,
Object value) |
VirtualCluster.Builder |
setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields) |
getAllFields, getField, getFieldBuilder, getOneofFieldDescriptor, getParentForChildren, getRepeatedField, getRepeatedFieldBuilder, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof, internalGetMapField, internalGetMutableMapField, isClean, markClean, newBuilderForField, onBuilt, onChanged, setUnknownFieldsProto3findInitializationErrors, getInitializationErrorString, internalMergeFrom, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException, toStringaddAll, addAll, mergeFrom, newUninitializedMessageExceptionequals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitpublic static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3.Builder<VirtualCluster.Builder>public VirtualCluster.Builder clear()
clear in interface com.google.protobuf.Message.Builderclear in interface com.google.protobuf.MessageLite.Builderclear in class com.google.protobuf.GeneratedMessageV3.Builder<VirtualCluster.Builder>public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
getDescriptorForType in interface com.google.protobuf.Message.BuildergetDescriptorForType in interface com.google.protobuf.MessageOrBuildergetDescriptorForType in class com.google.protobuf.GeneratedMessageV3.Builder<VirtualCluster.Builder>public VirtualCluster getDefaultInstanceForType()
getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuildergetDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilderpublic VirtualCluster build()
build in interface com.google.protobuf.Message.Builderbuild in interface com.google.protobuf.MessageLite.Builderpublic VirtualCluster buildPartial()
buildPartial in interface com.google.protobuf.Message.BuilderbuildPartial in interface com.google.protobuf.MessageLite.Builderpublic VirtualCluster.Builder clone()
clone in interface com.google.protobuf.Message.Builderclone in interface com.google.protobuf.MessageLite.Builderclone in class com.google.protobuf.GeneratedMessageV3.Builder<VirtualCluster.Builder>public VirtualCluster.Builder setField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
setField in interface com.google.protobuf.Message.BuildersetField in class com.google.protobuf.GeneratedMessageV3.Builder<VirtualCluster.Builder>public VirtualCluster.Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field)
clearField in interface com.google.protobuf.Message.BuilderclearField in class com.google.protobuf.GeneratedMessageV3.Builder<VirtualCluster.Builder>public VirtualCluster.Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof)
clearOneof in interface com.google.protobuf.Message.BuilderclearOneof in class com.google.protobuf.GeneratedMessageV3.Builder<VirtualCluster.Builder>public VirtualCluster.Builder setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value)
setRepeatedField in interface com.google.protobuf.Message.BuildersetRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<VirtualCluster.Builder>public VirtualCluster.Builder addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
addRepeatedField in interface com.google.protobuf.Message.BuilderaddRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<VirtualCluster.Builder>public VirtualCluster.Builder mergeFrom(com.google.protobuf.Message other)
mergeFrom in interface com.google.protobuf.Message.BuildermergeFrom in class com.google.protobuf.AbstractMessage.Builder<VirtualCluster.Builder>public VirtualCluster.Builder mergeFrom(VirtualCluster other)
public final boolean isInitialized()
isInitialized in interface com.google.protobuf.MessageLiteOrBuilderisInitialized in class com.google.protobuf.GeneratedMessageV3.Builder<VirtualCluster.Builder>public VirtualCluster.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
mergeFrom in interface com.google.protobuf.Message.BuildermergeFrom in interface com.google.protobuf.MessageLite.BuildermergeFrom in class com.google.protobuf.AbstractMessage.Builder<VirtualCluster.Builder>IOException@Deprecated public String getPattern()
Specifies a regex pattern to use for matching requests. The entire path of the request must match the regex. The regex grammar used is defined `here <https://en.cppreference.com/w/cpp/regex/ecmascript>`_. Examples: * The regex ``/rides/\d+`` matches the path */rides/0* * The regex ``/rides/\d+`` matches the path */rides/123* * The regex ``/rides/\d+`` does not match the path */rides/123/456* .. attention:: This field has been deprecated in favor of `headers` as it is not safe for use with untrusted input in all cases.
string pattern = 1 [deprecated = true, (.validate.rules) = { ... }getPattern in interface VirtualClusterOrBuilder@Deprecated public com.google.protobuf.ByteString getPatternBytes()
Specifies a regex pattern to use for matching requests. The entire path of the request must match the regex. The regex grammar used is defined `here <https://en.cppreference.com/w/cpp/regex/ecmascript>`_. Examples: * The regex ``/rides/\d+`` matches the path */rides/0* * The regex ``/rides/\d+`` matches the path */rides/123* * The regex ``/rides/\d+`` does not match the path */rides/123/456* .. attention:: This field has been deprecated in favor of `headers` as it is not safe for use with untrusted input in all cases.
string pattern = 1 [deprecated = true, (.validate.rules) = { ... }getPatternBytes in interface VirtualClusterOrBuilder@Deprecated public VirtualCluster.Builder setPattern(String value)
Specifies a regex pattern to use for matching requests. The entire path of the request must match the regex. The regex grammar used is defined `here <https://en.cppreference.com/w/cpp/regex/ecmascript>`_. Examples: * The regex ``/rides/\d+`` matches the path */rides/0* * The regex ``/rides/\d+`` matches the path */rides/123* * The regex ``/rides/\d+`` does not match the path */rides/123/456* .. attention:: This field has been deprecated in favor of `headers` as it is not safe for use with untrusted input in all cases.
string pattern = 1 [deprecated = true, (.validate.rules) = { ... }@Deprecated public VirtualCluster.Builder clearPattern()
Specifies a regex pattern to use for matching requests. The entire path of the request must match the regex. The regex grammar used is defined `here <https://en.cppreference.com/w/cpp/regex/ecmascript>`_. Examples: * The regex ``/rides/\d+`` matches the path */rides/0* * The regex ``/rides/\d+`` matches the path */rides/123* * The regex ``/rides/\d+`` does not match the path */rides/123/456* .. attention:: This field has been deprecated in favor of `headers` as it is not safe for use with untrusted input in all cases.
string pattern = 1 [deprecated = true, (.validate.rules) = { ... }@Deprecated public VirtualCluster.Builder setPatternBytes(com.google.protobuf.ByteString value)
Specifies a regex pattern to use for matching requests. The entire path of the request must match the regex. The regex grammar used is defined `here <https://en.cppreference.com/w/cpp/regex/ecmascript>`_. Examples: * The regex ``/rides/\d+`` matches the path */rides/0* * The regex ``/rides/\d+`` matches the path */rides/123* * The regex ``/rides/\d+`` does not match the path */rides/123/456* .. attention:: This field has been deprecated in favor of `headers` as it is not safe for use with untrusted input in all cases.
string pattern = 1 [deprecated = true, (.validate.rules) = { ... }public List<HeaderMatcher> getHeadersList()
Specifies a list of header matchers to use for matching requests. Each specified header must match. The pseudo-headers `:path` and `:method` can be used to match the request path and method, respectively.
repeated .envoy.api.v2.route.HeaderMatcher headers = 4;getHeadersList in interface VirtualClusterOrBuilderpublic int getHeadersCount()
Specifies a list of header matchers to use for matching requests. Each specified header must match. The pseudo-headers `:path` and `:method` can be used to match the request path and method, respectively.
repeated .envoy.api.v2.route.HeaderMatcher headers = 4;getHeadersCount in interface VirtualClusterOrBuilderpublic HeaderMatcher getHeaders(int index)
Specifies a list of header matchers to use for matching requests. Each specified header must match. The pseudo-headers `:path` and `:method` can be used to match the request path and method, respectively.
repeated .envoy.api.v2.route.HeaderMatcher headers = 4;getHeaders in interface VirtualClusterOrBuilderpublic VirtualCluster.Builder setHeaders(int index, HeaderMatcher value)
Specifies a list of header matchers to use for matching requests. Each specified header must match. The pseudo-headers `:path` and `:method` can be used to match the request path and method, respectively.
repeated .envoy.api.v2.route.HeaderMatcher headers = 4;public VirtualCluster.Builder setHeaders(int index, HeaderMatcher.Builder builderForValue)
Specifies a list of header matchers to use for matching requests. Each specified header must match. The pseudo-headers `:path` and `:method` can be used to match the request path and method, respectively.
repeated .envoy.api.v2.route.HeaderMatcher headers = 4;public VirtualCluster.Builder addHeaders(HeaderMatcher value)
Specifies a list of header matchers to use for matching requests. Each specified header must match. The pseudo-headers `:path` and `:method` can be used to match the request path and method, respectively.
repeated .envoy.api.v2.route.HeaderMatcher headers = 4;public VirtualCluster.Builder addHeaders(int index, HeaderMatcher value)
Specifies a list of header matchers to use for matching requests. Each specified header must match. The pseudo-headers `:path` and `:method` can be used to match the request path and method, respectively.
repeated .envoy.api.v2.route.HeaderMatcher headers = 4;public VirtualCluster.Builder addHeaders(HeaderMatcher.Builder builderForValue)
Specifies a list of header matchers to use for matching requests. Each specified header must match. The pseudo-headers `:path` and `:method` can be used to match the request path and method, respectively.
repeated .envoy.api.v2.route.HeaderMatcher headers = 4;public VirtualCluster.Builder addHeaders(int index, HeaderMatcher.Builder builderForValue)
Specifies a list of header matchers to use for matching requests. Each specified header must match. The pseudo-headers `:path` and `:method` can be used to match the request path and method, respectively.
repeated .envoy.api.v2.route.HeaderMatcher headers = 4;public VirtualCluster.Builder addAllHeaders(Iterable<? extends HeaderMatcher> values)
Specifies a list of header matchers to use for matching requests. Each specified header must match. The pseudo-headers `:path` and `:method` can be used to match the request path and method, respectively.
repeated .envoy.api.v2.route.HeaderMatcher headers = 4;public VirtualCluster.Builder clearHeaders()
Specifies a list of header matchers to use for matching requests. Each specified header must match. The pseudo-headers `:path` and `:method` can be used to match the request path and method, respectively.
repeated .envoy.api.v2.route.HeaderMatcher headers = 4;public VirtualCluster.Builder removeHeaders(int index)
Specifies a list of header matchers to use for matching requests. Each specified header must match. The pseudo-headers `:path` and `:method` can be used to match the request path and method, respectively.
repeated .envoy.api.v2.route.HeaderMatcher headers = 4;public HeaderMatcher.Builder getHeadersBuilder(int index)
Specifies a list of header matchers to use for matching requests. Each specified header must match. The pseudo-headers `:path` and `:method` can be used to match the request path and method, respectively.
repeated .envoy.api.v2.route.HeaderMatcher headers = 4;public HeaderMatcherOrBuilder getHeadersOrBuilder(int index)
Specifies a list of header matchers to use for matching requests. Each specified header must match. The pseudo-headers `:path` and `:method` can be used to match the request path and method, respectively.
repeated .envoy.api.v2.route.HeaderMatcher headers = 4;getHeadersOrBuilder in interface VirtualClusterOrBuilderpublic List<? extends HeaderMatcherOrBuilder> getHeadersOrBuilderList()
Specifies a list of header matchers to use for matching requests. Each specified header must match. The pseudo-headers `:path` and `:method` can be used to match the request path and method, respectively.
repeated .envoy.api.v2.route.HeaderMatcher headers = 4;getHeadersOrBuilderList in interface VirtualClusterOrBuilderpublic HeaderMatcher.Builder addHeadersBuilder()
Specifies a list of header matchers to use for matching requests. Each specified header must match. The pseudo-headers `:path` and `:method` can be used to match the request path and method, respectively.
repeated .envoy.api.v2.route.HeaderMatcher headers = 4;public HeaderMatcher.Builder addHeadersBuilder(int index)
Specifies a list of header matchers to use for matching requests. Each specified header must match. The pseudo-headers `:path` and `:method` can be used to match the request path and method, respectively.
repeated .envoy.api.v2.route.HeaderMatcher headers = 4;public List<HeaderMatcher.Builder> getHeadersBuilderList()
Specifies a list of header matchers to use for matching requests. Each specified header must match. The pseudo-headers `:path` and `:method` can be used to match the request path and method, respectively.
repeated .envoy.api.v2.route.HeaderMatcher headers = 4;public String getName()
Specifies the name of the virtual cluster. The virtual cluster name as well as the virtual host name are used when emitting statistics. The statistics are emitted by the router filter and are documented :ref:`here <config_http_filters_router_stats>`.
string name = 2 [(.validate.rules) = { ... }getName in interface VirtualClusterOrBuilderpublic com.google.protobuf.ByteString getNameBytes()
Specifies the name of the virtual cluster. The virtual cluster name as well as the virtual host name are used when emitting statistics. The statistics are emitted by the router filter and are documented :ref:`here <config_http_filters_router_stats>`.
string name = 2 [(.validate.rules) = { ... }getNameBytes in interface VirtualClusterOrBuilderpublic VirtualCluster.Builder setName(String value)
Specifies the name of the virtual cluster. The virtual cluster name as well as the virtual host name are used when emitting statistics. The statistics are emitted by the router filter and are documented :ref:`here <config_http_filters_router_stats>`.
string name = 2 [(.validate.rules) = { ... }public VirtualCluster.Builder clearName()
Specifies the name of the virtual cluster. The virtual cluster name as well as the virtual host name are used when emitting statistics. The statistics are emitted by the router filter and are documented :ref:`here <config_http_filters_router_stats>`.
string name = 2 [(.validate.rules) = { ... }public VirtualCluster.Builder setNameBytes(com.google.protobuf.ByteString value)
Specifies the name of the virtual cluster. The virtual cluster name as well as the virtual host name are used when emitting statistics. The statistics are emitted by the router filter and are documented :ref:`here <config_http_filters_router_stats>`.
string name = 2 [(.validate.rules) = { ... }@Deprecated public int getMethodValue()
Optionally specifies the HTTP method to match on. For example GET, PUT, etc. .. attention:: This field has been deprecated in favor of `headers`.
.envoy.api.v2.core.RequestMethod method = 3 [deprecated = true, (.envoy.annotations.disallowed_by_default) = true];getMethodValue in interface VirtualClusterOrBuilder@Deprecated public VirtualCluster.Builder setMethodValue(int value)
Optionally specifies the HTTP method to match on. For example GET, PUT, etc. .. attention:: This field has been deprecated in favor of `headers`.
.envoy.api.v2.core.RequestMethod method = 3 [deprecated = true, (.envoy.annotations.disallowed_by_default) = true];@Deprecated public RequestMethod getMethod()
Optionally specifies the HTTP method to match on. For example GET, PUT, etc. .. attention:: This field has been deprecated in favor of `headers`.
.envoy.api.v2.core.RequestMethod method = 3 [deprecated = true, (.envoy.annotations.disallowed_by_default) = true];getMethod in interface VirtualClusterOrBuilder@Deprecated public VirtualCluster.Builder setMethod(RequestMethod value)
Optionally specifies the HTTP method to match on. For example GET, PUT, etc. .. attention:: This field has been deprecated in favor of `headers`.
.envoy.api.v2.core.RequestMethod method = 3 [deprecated = true, (.envoy.annotations.disallowed_by_default) = true];@Deprecated public VirtualCluster.Builder clearMethod()
Optionally specifies the HTTP method to match on. For example GET, PUT, etc. .. attention:: This field has been deprecated in favor of `headers`.
.envoy.api.v2.core.RequestMethod method = 3 [deprecated = true, (.envoy.annotations.disallowed_by_default) = true];public final VirtualCluster.Builder setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
setUnknownFields in interface com.google.protobuf.Message.BuildersetUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<VirtualCluster.Builder>public final VirtualCluster.Builder mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
mergeUnknownFields in interface com.google.protobuf.Message.BuildermergeUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<VirtualCluster.Builder>Copyright © 2018–2021 The Envoy Project. All rights reserved.