public static final class TagSpecifier.Builder extends com.google.protobuf.GeneratedMessageV3.Builder<TagSpecifier.Builder> implements TagSpecifierOrBuilder
Designates a tag name and value pair. The value may be either a fixed value or a regex providing the value via capture groups. The specified tag will be unconditionally set if a fixed value, otherwise it will only be set if one or more capture groups in the regex match.Protobuf type
envoy.config.metrics.v4alpha.TagSpecifier| Modifier and Type | Method and Description |
|---|---|
TagSpecifier.Builder |
addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field,
Object value) |
TagSpecifier |
build() |
TagSpecifier |
buildPartial() |
TagSpecifier.Builder |
clear() |
TagSpecifier.Builder |
clearField(com.google.protobuf.Descriptors.FieldDescriptor field) |
TagSpecifier.Builder |
clearFixedValue()
Specifies a fixed tag value for the ``tag_name``.
|
TagSpecifier.Builder |
clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) |
TagSpecifier.Builder |
clearRegex()
Designates a tag to strip from the tag extracted name and provide as a named
tag value for all statistics.
|
TagSpecifier.Builder |
clearTagName()
Attaches an identifier to the tag values to identify the tag being in the
sink.
|
TagSpecifier.Builder |
clearTagValue() |
TagSpecifier.Builder |
clone() |
TagSpecifier |
getDefaultInstanceForType() |
static com.google.protobuf.Descriptors.Descriptor |
getDescriptor() |
com.google.protobuf.Descriptors.Descriptor |
getDescriptorForType() |
String |
getFixedValue()
Specifies a fixed tag value for the ``tag_name``.
|
com.google.protobuf.ByteString |
getFixedValueBytes()
Specifies a fixed tag value for the ``tag_name``.
|
String |
getRegex()
Designates a tag to strip from the tag extracted name and provide as a named
tag value for all statistics.
|
com.google.protobuf.ByteString |
getRegexBytes()
Designates a tag to strip from the tag extracted name and provide as a named
tag value for all statistics.
|
String |
getTagName()
Attaches an identifier to the tag values to identify the tag being in the
sink.
|
com.google.protobuf.ByteString |
getTagNameBytes()
Attaches an identifier to the tag values to identify the tag being in the
sink.
|
TagSpecifier.TagValueCase |
getTagValueCase() |
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable |
internalGetFieldAccessorTable() |
boolean |
isInitialized() |
TagSpecifier.Builder |
mergeFrom(com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
TagSpecifier.Builder |
mergeFrom(com.google.protobuf.Message other) |
TagSpecifier.Builder |
mergeFrom(TagSpecifier other) |
TagSpecifier.Builder |
mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields) |
TagSpecifier.Builder |
setField(com.google.protobuf.Descriptors.FieldDescriptor field,
Object value) |
TagSpecifier.Builder |
setFixedValue(String value)
Specifies a fixed tag value for the ``tag_name``.
|
TagSpecifier.Builder |
setFixedValueBytes(com.google.protobuf.ByteString value)
Specifies a fixed tag value for the ``tag_name``.
|
TagSpecifier.Builder |
setRegex(String value)
Designates a tag to strip from the tag extracted name and provide as a named
tag value for all statistics.
|
TagSpecifier.Builder |
setRegexBytes(com.google.protobuf.ByteString value)
Designates a tag to strip from the tag extracted name and provide as a named
tag value for all statistics.
|
TagSpecifier.Builder |
setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field,
int index,
Object value) |
TagSpecifier.Builder |
setTagName(String value)
Attaches an identifier to the tag values to identify the tag being in the
sink.
|
TagSpecifier.Builder |
setTagNameBytes(com.google.protobuf.ByteString value)
Attaches an identifier to the tag values to identify the tag being in the
sink.
|
TagSpecifier.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<TagSpecifier.Builder>public TagSpecifier.Builder clear()
clear in interface com.google.protobuf.Message.Builderclear in interface com.google.protobuf.MessageLite.Builderclear in class com.google.protobuf.GeneratedMessageV3.Builder<TagSpecifier.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<TagSpecifier.Builder>public TagSpecifier getDefaultInstanceForType()
getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuildergetDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilderpublic TagSpecifier build()
build in interface com.google.protobuf.Message.Builderbuild in interface com.google.protobuf.MessageLite.Builderpublic TagSpecifier buildPartial()
buildPartial in interface com.google.protobuf.Message.BuilderbuildPartial in interface com.google.protobuf.MessageLite.Builderpublic TagSpecifier.Builder clone()
clone in interface com.google.protobuf.Message.Builderclone in interface com.google.protobuf.MessageLite.Builderclone in class com.google.protobuf.GeneratedMessageV3.Builder<TagSpecifier.Builder>public TagSpecifier.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<TagSpecifier.Builder>public TagSpecifier.Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field)
clearField in interface com.google.protobuf.Message.BuilderclearField in class com.google.protobuf.GeneratedMessageV3.Builder<TagSpecifier.Builder>public TagSpecifier.Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof)
clearOneof in interface com.google.protobuf.Message.BuilderclearOneof in class com.google.protobuf.GeneratedMessageV3.Builder<TagSpecifier.Builder>public TagSpecifier.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<TagSpecifier.Builder>public TagSpecifier.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<TagSpecifier.Builder>public TagSpecifier.Builder mergeFrom(com.google.protobuf.Message other)
mergeFrom in interface com.google.protobuf.Message.BuildermergeFrom in class com.google.protobuf.AbstractMessage.Builder<TagSpecifier.Builder>public TagSpecifier.Builder mergeFrom(TagSpecifier other)
public final boolean isInitialized()
isInitialized in interface com.google.protobuf.MessageLiteOrBuilderisInitialized in class com.google.protobuf.GeneratedMessageV3.Builder<TagSpecifier.Builder>public TagSpecifier.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<TagSpecifier.Builder>IOExceptionpublic TagSpecifier.TagValueCase getTagValueCase()
getTagValueCase in interface TagSpecifierOrBuilderpublic TagSpecifier.Builder clearTagValue()
public String getTagName()
Attaches an identifier to the tag values to identify the tag being in the sink. Envoy has a set of default names and regexes to extract dynamic portions of existing stats, which can be found in :repo:`well_known_names.h <source/common/config/well_known_names.h>` in the Envoy repository. If a :ref:`tag_name <envoy_api_field_config.metrics.v4alpha.TagSpecifier.tag_name>` is provided in the config and neither :ref:`regex <envoy_api_field_config.metrics.v4alpha.TagSpecifier.regex>` or :ref:`fixed_value <envoy_api_field_config.metrics.v4alpha.TagSpecifier.fixed_value>` were specified, Envoy will attempt to find that name in its set of defaults and use the accompanying regex. .. note:: It is invalid to specify the same tag name twice in a config.
string tag_name = 1;getTagName in interface TagSpecifierOrBuilderpublic com.google.protobuf.ByteString getTagNameBytes()
Attaches an identifier to the tag values to identify the tag being in the sink. Envoy has a set of default names and regexes to extract dynamic portions of existing stats, which can be found in :repo:`well_known_names.h <source/common/config/well_known_names.h>` in the Envoy repository. If a :ref:`tag_name <envoy_api_field_config.metrics.v4alpha.TagSpecifier.tag_name>` is provided in the config and neither :ref:`regex <envoy_api_field_config.metrics.v4alpha.TagSpecifier.regex>` or :ref:`fixed_value <envoy_api_field_config.metrics.v4alpha.TagSpecifier.fixed_value>` were specified, Envoy will attempt to find that name in its set of defaults and use the accompanying regex. .. note:: It is invalid to specify the same tag name twice in a config.
string tag_name = 1;getTagNameBytes in interface TagSpecifierOrBuilderpublic TagSpecifier.Builder setTagName(String value)
Attaches an identifier to the tag values to identify the tag being in the sink. Envoy has a set of default names and regexes to extract dynamic portions of existing stats, which can be found in :repo:`well_known_names.h <source/common/config/well_known_names.h>` in the Envoy repository. If a :ref:`tag_name <envoy_api_field_config.metrics.v4alpha.TagSpecifier.tag_name>` is provided in the config and neither :ref:`regex <envoy_api_field_config.metrics.v4alpha.TagSpecifier.regex>` or :ref:`fixed_value <envoy_api_field_config.metrics.v4alpha.TagSpecifier.fixed_value>` were specified, Envoy will attempt to find that name in its set of defaults and use the accompanying regex. .. note:: It is invalid to specify the same tag name twice in a config.
string tag_name = 1;public TagSpecifier.Builder clearTagName()
Attaches an identifier to the tag values to identify the tag being in the sink. Envoy has a set of default names and regexes to extract dynamic portions of existing stats, which can be found in :repo:`well_known_names.h <source/common/config/well_known_names.h>` in the Envoy repository. If a :ref:`tag_name <envoy_api_field_config.metrics.v4alpha.TagSpecifier.tag_name>` is provided in the config and neither :ref:`regex <envoy_api_field_config.metrics.v4alpha.TagSpecifier.regex>` or :ref:`fixed_value <envoy_api_field_config.metrics.v4alpha.TagSpecifier.fixed_value>` were specified, Envoy will attempt to find that name in its set of defaults and use the accompanying regex. .. note:: It is invalid to specify the same tag name twice in a config.
string tag_name = 1;public TagSpecifier.Builder setTagNameBytes(com.google.protobuf.ByteString value)
Attaches an identifier to the tag values to identify the tag being in the sink. Envoy has a set of default names and regexes to extract dynamic portions of existing stats, which can be found in :repo:`well_known_names.h <source/common/config/well_known_names.h>` in the Envoy repository. If a :ref:`tag_name <envoy_api_field_config.metrics.v4alpha.TagSpecifier.tag_name>` is provided in the config and neither :ref:`regex <envoy_api_field_config.metrics.v4alpha.TagSpecifier.regex>` or :ref:`fixed_value <envoy_api_field_config.metrics.v4alpha.TagSpecifier.fixed_value>` were specified, Envoy will attempt to find that name in its set of defaults and use the accompanying regex. .. note:: It is invalid to specify the same tag name twice in a config.
string tag_name = 1;public String getRegex()
Designates a tag to strip from the tag extracted name and provide as a named
tag value for all statistics. This will only occur if any part of the name
matches the regex provided with one or more capture groups.
The first capture group identifies the portion of the name to remove. The
second capture group (which will normally be nested inside the first) will
designate the value of the tag for the statistic. If no second capture
group is provided, the first will also be used to set the value of the tag.
All other capture groups will be ignored.
Example 1. a stat name ``cluster.foo_cluster.upstream_rq_timeout`` and
one tag specifier:
.. code-block:: json
{
"tag_name": "envoy.cluster_name",
"regex": "^cluster\\.((.+?)\\.)"
}
Note that the regex will remove ``foo_cluster.`` making the tag extracted
name ``cluster.upstream_rq_timeout`` and the tag value for
``envoy.cluster_name`` will be ``foo_cluster`` (note: there will be no
``.`` character because of the second capture group).
Example 2. a stat name
``http.connection_manager_1.user_agent.ios.downstream_cx_total`` and two
tag specifiers:
.. code-block:: json
[
{
"tag_name": "envoy.http_user_agent",
"regex": "^http(?=\\.).*?\\.user_agent\\.((.+?)\\.)\\w+?$"
},
{
"tag_name": "envoy.http_conn_manager_prefix",
"regex": "^http\\.((.*?)\\.)"
}
]
The two regexes of the specifiers will be processed in the definition order.
The first regex will remove ``ios.``, leaving the tag extracted name
``http.connection_manager_1.user_agent.downstream_cx_total``. The tag
``envoy.http_user_agent`` will be added with tag value ``ios``.
The second regex will remove ``connection_manager_1.`` from the tag
extracted name produced by the first regex
``http.connection_manager_1.user_agent.downstream_cx_total``, leaving
``http.user_agent.downstream_cx_total`` as the tag extracted name. The tag
``envoy.http_conn_manager_prefix`` will be added with the tag value
``connection_manager_1``.
string regex = 2 [(.validate.rules) = { ... }getRegex in interface TagSpecifierOrBuilderpublic com.google.protobuf.ByteString getRegexBytes()
Designates a tag to strip from the tag extracted name and provide as a named
tag value for all statistics. This will only occur if any part of the name
matches the regex provided with one or more capture groups.
The first capture group identifies the portion of the name to remove. The
second capture group (which will normally be nested inside the first) will
designate the value of the tag for the statistic. If no second capture
group is provided, the first will also be used to set the value of the tag.
All other capture groups will be ignored.
Example 1. a stat name ``cluster.foo_cluster.upstream_rq_timeout`` and
one tag specifier:
.. code-block:: json
{
"tag_name": "envoy.cluster_name",
"regex": "^cluster\\.((.+?)\\.)"
}
Note that the regex will remove ``foo_cluster.`` making the tag extracted
name ``cluster.upstream_rq_timeout`` and the tag value for
``envoy.cluster_name`` will be ``foo_cluster`` (note: there will be no
``.`` character because of the second capture group).
Example 2. a stat name
``http.connection_manager_1.user_agent.ios.downstream_cx_total`` and two
tag specifiers:
.. code-block:: json
[
{
"tag_name": "envoy.http_user_agent",
"regex": "^http(?=\\.).*?\\.user_agent\\.((.+?)\\.)\\w+?$"
},
{
"tag_name": "envoy.http_conn_manager_prefix",
"regex": "^http\\.((.*?)\\.)"
}
]
The two regexes of the specifiers will be processed in the definition order.
The first regex will remove ``ios.``, leaving the tag extracted name
``http.connection_manager_1.user_agent.downstream_cx_total``. The tag
``envoy.http_user_agent`` will be added with tag value ``ios``.
The second regex will remove ``connection_manager_1.`` from the tag
extracted name produced by the first regex
``http.connection_manager_1.user_agent.downstream_cx_total``, leaving
``http.user_agent.downstream_cx_total`` as the tag extracted name. The tag
``envoy.http_conn_manager_prefix`` will be added with the tag value
``connection_manager_1``.
string regex = 2 [(.validate.rules) = { ... }getRegexBytes in interface TagSpecifierOrBuilderpublic TagSpecifier.Builder setRegex(String value)
Designates a tag to strip from the tag extracted name and provide as a named
tag value for all statistics. This will only occur if any part of the name
matches the regex provided with one or more capture groups.
The first capture group identifies the portion of the name to remove. The
second capture group (which will normally be nested inside the first) will
designate the value of the tag for the statistic. If no second capture
group is provided, the first will also be used to set the value of the tag.
All other capture groups will be ignored.
Example 1. a stat name ``cluster.foo_cluster.upstream_rq_timeout`` and
one tag specifier:
.. code-block:: json
{
"tag_name": "envoy.cluster_name",
"regex": "^cluster\\.((.+?)\\.)"
}
Note that the regex will remove ``foo_cluster.`` making the tag extracted
name ``cluster.upstream_rq_timeout`` and the tag value for
``envoy.cluster_name`` will be ``foo_cluster`` (note: there will be no
``.`` character because of the second capture group).
Example 2. a stat name
``http.connection_manager_1.user_agent.ios.downstream_cx_total`` and two
tag specifiers:
.. code-block:: json
[
{
"tag_name": "envoy.http_user_agent",
"regex": "^http(?=\\.).*?\\.user_agent\\.((.+?)\\.)\\w+?$"
},
{
"tag_name": "envoy.http_conn_manager_prefix",
"regex": "^http\\.((.*?)\\.)"
}
]
The two regexes of the specifiers will be processed in the definition order.
The first regex will remove ``ios.``, leaving the tag extracted name
``http.connection_manager_1.user_agent.downstream_cx_total``. The tag
``envoy.http_user_agent`` will be added with tag value ``ios``.
The second regex will remove ``connection_manager_1.`` from the tag
extracted name produced by the first regex
``http.connection_manager_1.user_agent.downstream_cx_total``, leaving
``http.user_agent.downstream_cx_total`` as the tag extracted name. The tag
``envoy.http_conn_manager_prefix`` will be added with the tag value
``connection_manager_1``.
string regex = 2 [(.validate.rules) = { ... }public TagSpecifier.Builder clearRegex()
Designates a tag to strip from the tag extracted name and provide as a named
tag value for all statistics. This will only occur if any part of the name
matches the regex provided with one or more capture groups.
The first capture group identifies the portion of the name to remove. The
second capture group (which will normally be nested inside the first) will
designate the value of the tag for the statistic. If no second capture
group is provided, the first will also be used to set the value of the tag.
All other capture groups will be ignored.
Example 1. a stat name ``cluster.foo_cluster.upstream_rq_timeout`` and
one tag specifier:
.. code-block:: json
{
"tag_name": "envoy.cluster_name",
"regex": "^cluster\\.((.+?)\\.)"
}
Note that the regex will remove ``foo_cluster.`` making the tag extracted
name ``cluster.upstream_rq_timeout`` and the tag value for
``envoy.cluster_name`` will be ``foo_cluster`` (note: there will be no
``.`` character because of the second capture group).
Example 2. a stat name
``http.connection_manager_1.user_agent.ios.downstream_cx_total`` and two
tag specifiers:
.. code-block:: json
[
{
"tag_name": "envoy.http_user_agent",
"regex": "^http(?=\\.).*?\\.user_agent\\.((.+?)\\.)\\w+?$"
},
{
"tag_name": "envoy.http_conn_manager_prefix",
"regex": "^http\\.((.*?)\\.)"
}
]
The two regexes of the specifiers will be processed in the definition order.
The first regex will remove ``ios.``, leaving the tag extracted name
``http.connection_manager_1.user_agent.downstream_cx_total``. The tag
``envoy.http_user_agent`` will be added with tag value ``ios``.
The second regex will remove ``connection_manager_1.`` from the tag
extracted name produced by the first regex
``http.connection_manager_1.user_agent.downstream_cx_total``, leaving
``http.user_agent.downstream_cx_total`` as the tag extracted name. The tag
``envoy.http_conn_manager_prefix`` will be added with the tag value
``connection_manager_1``.
string regex = 2 [(.validate.rules) = { ... }public TagSpecifier.Builder setRegexBytes(com.google.protobuf.ByteString value)
Designates a tag to strip from the tag extracted name and provide as a named
tag value for all statistics. This will only occur if any part of the name
matches the regex provided with one or more capture groups.
The first capture group identifies the portion of the name to remove. The
second capture group (which will normally be nested inside the first) will
designate the value of the tag for the statistic. If no second capture
group is provided, the first will also be used to set the value of the tag.
All other capture groups will be ignored.
Example 1. a stat name ``cluster.foo_cluster.upstream_rq_timeout`` and
one tag specifier:
.. code-block:: json
{
"tag_name": "envoy.cluster_name",
"regex": "^cluster\\.((.+?)\\.)"
}
Note that the regex will remove ``foo_cluster.`` making the tag extracted
name ``cluster.upstream_rq_timeout`` and the tag value for
``envoy.cluster_name`` will be ``foo_cluster`` (note: there will be no
``.`` character because of the second capture group).
Example 2. a stat name
``http.connection_manager_1.user_agent.ios.downstream_cx_total`` and two
tag specifiers:
.. code-block:: json
[
{
"tag_name": "envoy.http_user_agent",
"regex": "^http(?=\\.).*?\\.user_agent\\.((.+?)\\.)\\w+?$"
},
{
"tag_name": "envoy.http_conn_manager_prefix",
"regex": "^http\\.((.*?)\\.)"
}
]
The two regexes of the specifiers will be processed in the definition order.
The first regex will remove ``ios.``, leaving the tag extracted name
``http.connection_manager_1.user_agent.downstream_cx_total``. The tag
``envoy.http_user_agent`` will be added with tag value ``ios``.
The second regex will remove ``connection_manager_1.`` from the tag
extracted name produced by the first regex
``http.connection_manager_1.user_agent.downstream_cx_total``, leaving
``http.user_agent.downstream_cx_total`` as the tag extracted name. The tag
``envoy.http_conn_manager_prefix`` will be added with the tag value
``connection_manager_1``.
string regex = 2 [(.validate.rules) = { ... }public String getFixedValue()
Specifies a fixed tag value for the ``tag_name``.
string fixed_value = 3;getFixedValue in interface TagSpecifierOrBuilderpublic com.google.protobuf.ByteString getFixedValueBytes()
Specifies a fixed tag value for the ``tag_name``.
string fixed_value = 3;getFixedValueBytes in interface TagSpecifierOrBuilderpublic TagSpecifier.Builder setFixedValue(String value)
Specifies a fixed tag value for the ``tag_name``.
string fixed_value = 3;public TagSpecifier.Builder clearFixedValue()
Specifies a fixed tag value for the ``tag_name``.
string fixed_value = 3;public TagSpecifier.Builder setFixedValueBytes(com.google.protobuf.ByteString value)
Specifies a fixed tag value for the ``tag_name``.
string fixed_value = 3;public final TagSpecifier.Builder setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
setUnknownFields in interface com.google.protobuf.Message.BuildersetUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<TagSpecifier.Builder>public final TagSpecifier.Builder mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
mergeUnknownFields in interface com.google.protobuf.Message.BuildermergeUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<TagSpecifier.Builder>Copyright © 2018–2021 The Envoy Project. All rights reserved.