Class: Google::Cloud::NetworkServices::V1::EndpointMatcher::MetadataLabelMatcher
- Inherits:
-
Object
- Object
- Google::Cloud::NetworkServices::V1::EndpointMatcher::MetadataLabelMatcher
- Extended by:
- Protobuf::MessageExts::ClassMethods
- Includes:
- Protobuf::MessageExts
- Defined in:
- proto_docs/google/cloud/networkservices/v1/common.rb
Overview
The matcher that is based on node metadata presented by xDS clients.
Defined Under Namespace
Modules: MetadataLabelMatchCriteria Classes: MetadataLabels
Instance Attribute Summary collapse
-
#metadata_label_match_criteria ⇒ ::Google::Cloud::NetworkServices::V1::EndpointMatcher::MetadataLabelMatcher::MetadataLabelMatchCriteria
Specifies how matching should be done.
-
#metadata_labels ⇒ ::Array<::Google::Cloud::NetworkServices::V1::EndpointMatcher::MetadataLabelMatcher::MetadataLabels>
The list of label value pairs that must match labels in the provided metadata based on filterMatchCriteria This list can have at most 64 entries.
Instance Attribute Details
#metadata_label_match_criteria ⇒ ::Google::Cloud::NetworkServices::V1::EndpointMatcher::MetadataLabelMatcher::MetadataLabelMatchCriteria
Returns Specifies how matching should be done.
Supported values are: MATCH_ANY: At least one of the Labels specified in the matcher should match the metadata presented by xDS client. MATCH_ALL: The metadata presented by the xDS client should contain all of the labels specified here.
The selection is determined based on the best match. For
example, suppose there are three EndpointPolicy
resources P1, P2 and P3 and if P1 has a the matcher as
MATCH_ANY
If a client with label
If a client with label
If a client with label
If there is more than one best match, (for example, if a
config P4 with selector
112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 |
# File 'proto_docs/google/cloud/networkservices/v1/common.rb', line 112 class MetadataLabelMatcher include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Defines a name-pair value for a single label. # @!attribute [rw] label_name # @return [::String] # Required. Label name presented as key in xDS Node Metadata. # @!attribute [rw] label_value # @return [::String] # Required. Label value presented as value corresponding to the above # key, in xDS Node Metadata. class MetadataLabels include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Possible criteria values that define logic of how matching is made. module MetadataLabelMatchCriteria # Default value. Should not be used. METADATA_LABEL_MATCH_CRITERIA_UNSPECIFIED = 0 # At least one of the Labels specified in the matcher should match the # metadata presented by xDS client. MATCH_ANY = 1 # The metadata presented by the xDS client should contain all of the # labels specified here. MATCH_ALL = 2 end end |
#metadata_labels ⇒ ::Array<::Google::Cloud::NetworkServices::V1::EndpointMatcher::MetadataLabelMatcher::MetadataLabels>
Returns The list of label value pairs that must match labels in the provided metadata based on filterMatchCriteria This list can have at most 64 entries. The list can be empty if the match criteria is MATCH_ANY, to specify a wildcard match (i.e this matches any client).
112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 |
# File 'proto_docs/google/cloud/networkservices/v1/common.rb', line 112 class MetadataLabelMatcher include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Defines a name-pair value for a single label. # @!attribute [rw] label_name # @return [::String] # Required. Label name presented as key in xDS Node Metadata. # @!attribute [rw] label_value # @return [::String] # Required. Label value presented as value corresponding to the above # key, in xDS Node Metadata. class MetadataLabels include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Possible criteria values that define logic of how matching is made. module MetadataLabelMatchCriteria # Default value. Should not be used. METADATA_LABEL_MATCH_CRITERIA_UNSPECIFIED = 0 # At least one of the Labels specified in the matcher should match the # metadata presented by xDS client. MATCH_ANY = 1 # The metadata presented by the xDS client should contain all of the # labels specified here. MATCH_ALL = 2 end end |