Class EndpointMatcher.MetadataLabelMatcher

java.lang.Object
com.google.protobuf.AbstractMessageLite
com.google.protobuf.AbstractMessage
com.google.protobuf.GeneratedMessage
com.google.cloud.networkservices.v1.EndpointMatcher.MetadataLabelMatcher
All Implemented Interfaces:
EndpointMatcher.MetadataLabelMatcherOrBuilder, com.google.protobuf.Message, com.google.protobuf.MessageLite, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Serializable
Enclosing class:
EndpointMatcher

public static final class EndpointMatcher.MetadataLabelMatcher extends com.google.protobuf.GeneratedMessage implements EndpointMatcher.MetadataLabelMatcherOrBuilder
 The matcher that is based on node metadata presented by xDS clients.
 
Protobuf type google.cloud.networkservices.v1.EndpointMatcher.MetadataLabelMatcher
See Also:
  • Field Details

    • METADATA_LABEL_MATCH_CRITERIA_FIELD_NUMBER

      public static final int METADATA_LABEL_MATCH_CRITERIA_FIELD_NUMBER
      See Also:
    • METADATA_LABELS_FIELD_NUMBER

      public static final int METADATA_LABELS_FIELD_NUMBER
      See Also:
  • Method Details

    • getDescriptor

      public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
    • internalGetFieldAccessorTable

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
      Specified by:
      internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessage
    • getMetadataLabelMatchCriteriaValue

      public int getMetadataLabelMatchCriteriaValue()
       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 <A:1, B:1>, P2 has MATCH_ALL <A:1,B:1>, and P3 has
       MATCH_ALL <A:1,B:1,C:1>.
      
       If a client with label <A:1> connects, the config from P1
       will be selected.
      
       If a client with label <A:1,B:1> connects, the config from P2
       will be selected.
      
       If a client with label <A:1,B:1,C:1> connects, the config
       from P3 will be selected.
      
       If there is more than one best match, (for example, if a
       config P4 with selector <A:1,D:1> exists and if a client with
       label <A:1,B:1,D:1> connects), pick up the one with older creation time.
       
      .google.cloud.networkservices.v1.EndpointMatcher.MetadataLabelMatcher.MetadataLabelMatchCriteria metadata_label_match_criteria = 1;
      Specified by:
      getMetadataLabelMatchCriteriaValue in interface EndpointMatcher.MetadataLabelMatcherOrBuilder
      Returns:
      The enum numeric value on the wire for metadataLabelMatchCriteria.
    • getMetadataLabelMatchCriteria

       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 <A:1, B:1>, P2 has MATCH_ALL <A:1,B:1>, and P3 has
       MATCH_ALL <A:1,B:1,C:1>.
      
       If a client with label <A:1> connects, the config from P1
       will be selected.
      
       If a client with label <A:1,B:1> connects, the config from P2
       will be selected.
      
       If a client with label <A:1,B:1,C:1> connects, the config
       from P3 will be selected.
      
       If there is more than one best match, (for example, if a
       config P4 with selector <A:1,D:1> exists and if a client with
       label <A:1,B:1,D:1> connects), pick up the one with older creation time.
       
      .google.cloud.networkservices.v1.EndpointMatcher.MetadataLabelMatcher.MetadataLabelMatchCriteria metadata_label_match_criteria = 1;
      Specified by:
      getMetadataLabelMatchCriteria in interface EndpointMatcher.MetadataLabelMatcherOrBuilder
      Returns:
      The metadataLabelMatchCriteria.
    • getMetadataLabelsList

       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).
       
      repeated .google.cloud.networkservices.v1.EndpointMatcher.MetadataLabelMatcher.MetadataLabels metadata_labels = 2;
      Specified by:
      getMetadataLabelsList in interface EndpointMatcher.MetadataLabelMatcherOrBuilder
    • getMetadataLabelsOrBuilderList

      public List<? extends EndpointMatcher.MetadataLabelMatcher.MetadataLabelsOrBuilder> getMetadataLabelsOrBuilderList()
       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).
       
      repeated .google.cloud.networkservices.v1.EndpointMatcher.MetadataLabelMatcher.MetadataLabels metadata_labels = 2;
      Specified by:
      getMetadataLabelsOrBuilderList in interface EndpointMatcher.MetadataLabelMatcherOrBuilder
    • getMetadataLabelsCount

      public int getMetadataLabelsCount()
       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).
       
      repeated .google.cloud.networkservices.v1.EndpointMatcher.MetadataLabelMatcher.MetadataLabels metadata_labels = 2;
      Specified by:
      getMetadataLabelsCount in interface EndpointMatcher.MetadataLabelMatcherOrBuilder
    • getMetadataLabels

      public EndpointMatcher.MetadataLabelMatcher.MetadataLabels getMetadataLabels(int index)
       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).
       
      repeated .google.cloud.networkservices.v1.EndpointMatcher.MetadataLabelMatcher.MetadataLabels metadata_labels = 2;
      Specified by:
      getMetadataLabels in interface EndpointMatcher.MetadataLabelMatcherOrBuilder
    • getMetadataLabelsOrBuilder

      public EndpointMatcher.MetadataLabelMatcher.MetadataLabelsOrBuilder getMetadataLabelsOrBuilder(int index)
       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).
       
      repeated .google.cloud.networkservices.v1.EndpointMatcher.MetadataLabelMatcher.MetadataLabels metadata_labels = 2;
      Specified by:
      getMetadataLabelsOrBuilder in interface EndpointMatcher.MetadataLabelMatcherOrBuilder
    • isInitialized

      public final boolean isInitialized()
      Specified by:
      isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
      Overrides:
      isInitialized in class com.google.protobuf.GeneratedMessage
    • writeTo

      public void writeTo(com.google.protobuf.CodedOutputStream output) throws IOException
      Specified by:
      writeTo in interface com.google.protobuf.MessageLite
      Overrides:
      writeTo in class com.google.protobuf.GeneratedMessage
      Throws:
      IOException
    • getSerializedSize

      public int getSerializedSize()
      Specified by:
      getSerializedSize in interface com.google.protobuf.MessageLite
      Overrides:
      getSerializedSize in class com.google.protobuf.GeneratedMessage
    • equals

      public boolean equals(Object obj)
      Specified by:
      equals in interface com.google.protobuf.Message
      Overrides:
      equals in class com.google.protobuf.AbstractMessage
    • hashCode

      public int hashCode()
      Specified by:
      hashCode in interface com.google.protobuf.Message
      Overrides:
      hashCode in class com.google.protobuf.AbstractMessage
    • parseFrom

      public static EndpointMatcher.MetadataLabelMatcher parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static EndpointMatcher.MetadataLabelMatcher parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static EndpointMatcher.MetadataLabelMatcher parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static EndpointMatcher.MetadataLabelMatcher parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static EndpointMatcher.MetadataLabelMatcher parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static EndpointMatcher.MetadataLabelMatcher parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static EndpointMatcher.MetadataLabelMatcher parseFrom(InputStream input) throws IOException
      Throws:
      IOException
    • parseFrom

      public static EndpointMatcher.MetadataLabelMatcher parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Throws:
      IOException
    • parseDelimitedFrom

      public static EndpointMatcher.MetadataLabelMatcher parseDelimitedFrom(InputStream input) throws IOException
      Throws:
      IOException
    • parseDelimitedFrom

      public static EndpointMatcher.MetadataLabelMatcher parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Throws:
      IOException
    • parseFrom

      public static EndpointMatcher.MetadataLabelMatcher parseFrom(com.google.protobuf.CodedInputStream input) throws IOException
      Throws:
      IOException
    • parseFrom

      public static EndpointMatcher.MetadataLabelMatcher parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Throws:
      IOException
    • newBuilderForType

      Specified by:
      newBuilderForType in interface com.google.protobuf.Message
      Specified by:
      newBuilderForType in interface com.google.protobuf.MessageLite
    • newBuilder

    • newBuilder

    • toBuilder

      Specified by:
      toBuilder in interface com.google.protobuf.Message
      Specified by:
      toBuilder in interface com.google.protobuf.MessageLite
    • newBuilderForType

      protected EndpointMatcher.MetadataLabelMatcher.Builder newBuilderForType(com.google.protobuf.AbstractMessage.BuilderParent parent)
      Overrides:
      newBuilderForType in class com.google.protobuf.AbstractMessage
    • getDefaultInstance

      public static EndpointMatcher.MetadataLabelMatcher getDefaultInstance()
    • parser

      public static com.google.protobuf.Parser<EndpointMatcher.MetadataLabelMatcher> parser()
    • getParserForType

      public com.google.protobuf.Parser<EndpointMatcher.MetadataLabelMatcher> getParserForType()
      Specified by:
      getParserForType in interface com.google.protobuf.Message
      Specified by:
      getParserForType in interface com.google.protobuf.MessageLite
      Overrides:
      getParserForType in class com.google.protobuf.GeneratedMessage
    • getDefaultInstanceForType

      public EndpointMatcher.MetadataLabelMatcher getDefaultInstanceForType()
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder