Class HttpRoute.Destination

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

public static final class HttpRoute.Destination extends com.google.protobuf.GeneratedMessage implements HttpRoute.DestinationOrBuilder
 Specifications of a destination to which the request should be routed to.
 
Protobuf type google.cloud.networkservices.v1.HttpRoute.Destination
See Also:
  • Field Details

    • SERVICE_NAME_FIELD_NUMBER

      public static final int SERVICE_NAME_FIELD_NUMBER
      See Also:
    • WEIGHT_FIELD_NUMBER

      public static final int WEIGHT_FIELD_NUMBER
      See Also:
    • REQUEST_HEADER_MODIFIER_FIELD_NUMBER

      public static final int REQUEST_HEADER_MODIFIER_FIELD_NUMBER
      See Also:
    • RESPONSE_HEADER_MODIFIER_FIELD_NUMBER

      public static final int RESPONSE_HEADER_MODIFIER_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
    • getServiceName

      public String getServiceName()
       The URL of a BackendService to route traffic to.
       
      string service_name = 1 [(.google.api.resource_reference) = { ... }
      Specified by:
      getServiceName in interface HttpRoute.DestinationOrBuilder
      Returns:
      The serviceName.
    • getServiceNameBytes

      public com.google.protobuf.ByteString getServiceNameBytes()
       The URL of a BackendService to route traffic to.
       
      string service_name = 1 [(.google.api.resource_reference) = { ... }
      Specified by:
      getServiceNameBytes in interface HttpRoute.DestinationOrBuilder
      Returns:
      The bytes for serviceName.
    • getWeight

      public int getWeight()
       Specifies the proportion of requests forwarded to the backend referenced
       by the serviceName field. This is computed as:
       - weight/Sum(weights in this destination list).
       For non-zero values, there may be some epsilon from the exact proportion
       defined here depending on the precision an implementation supports.
      
       If only one serviceName is specified and it has a weight greater than 0,
       100% of the traffic is forwarded to that backend.
      
       If weights are specified for any one service name, they need to be
       specified for all of them.
      
       If weights are unspecified for all services, then, traffic is distributed
       in equal proportions to all of them.
       
      int32 weight = 2;
      Specified by:
      getWeight in interface HttpRoute.DestinationOrBuilder
      Returns:
      The weight.
    • hasRequestHeaderModifier

      public boolean hasRequestHeaderModifier()
       Optional. The specification for modifying the headers of a matching
       request prior to delivery of the request to the destination. If
       HeaderModifiers are set on both the Destination and the RouteAction, they
       will be merged. Conflicts between the two will not be resolved on the
       configuration.
       
      .google.cloud.networkservices.v1.HttpRoute.HeaderModifier request_header_modifier = 3 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      hasRequestHeaderModifier in interface HttpRoute.DestinationOrBuilder
      Returns:
      Whether the requestHeaderModifier field is set.
    • getRequestHeaderModifier

      public HttpRoute.HeaderModifier getRequestHeaderModifier()
       Optional. The specification for modifying the headers of a matching
       request prior to delivery of the request to the destination. If
       HeaderModifiers are set on both the Destination and the RouteAction, they
       will be merged. Conflicts between the two will not be resolved on the
       configuration.
       
      .google.cloud.networkservices.v1.HttpRoute.HeaderModifier request_header_modifier = 3 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getRequestHeaderModifier in interface HttpRoute.DestinationOrBuilder
      Returns:
      The requestHeaderModifier.
    • getRequestHeaderModifierOrBuilder

      public HttpRoute.HeaderModifierOrBuilder getRequestHeaderModifierOrBuilder()
       Optional. The specification for modifying the headers of a matching
       request prior to delivery of the request to the destination. If
       HeaderModifiers are set on both the Destination and the RouteAction, they
       will be merged. Conflicts between the two will not be resolved on the
       configuration.
       
      .google.cloud.networkservices.v1.HttpRoute.HeaderModifier request_header_modifier = 3 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getRequestHeaderModifierOrBuilder in interface HttpRoute.DestinationOrBuilder
    • hasResponseHeaderModifier

      public boolean hasResponseHeaderModifier()
       Optional. The specification for modifying the headers of a response prior
       to sending the response back to the client. If HeaderModifiers are set on
       both the Destination and the RouteAction, they will be merged. Conflicts
       between the two will not be resolved on the configuration.
       
      .google.cloud.networkservices.v1.HttpRoute.HeaderModifier response_header_modifier = 4 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      hasResponseHeaderModifier in interface HttpRoute.DestinationOrBuilder
      Returns:
      Whether the responseHeaderModifier field is set.
    • getResponseHeaderModifier

      public HttpRoute.HeaderModifier getResponseHeaderModifier()
       Optional. The specification for modifying the headers of a response prior
       to sending the response back to the client. If HeaderModifiers are set on
       both the Destination and the RouteAction, they will be merged. Conflicts
       between the two will not be resolved on the configuration.
       
      .google.cloud.networkservices.v1.HttpRoute.HeaderModifier response_header_modifier = 4 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getResponseHeaderModifier in interface HttpRoute.DestinationOrBuilder
      Returns:
      The responseHeaderModifier.
    • getResponseHeaderModifierOrBuilder

      public HttpRoute.HeaderModifierOrBuilder getResponseHeaderModifierOrBuilder()
       Optional. The specification for modifying the headers of a response prior
       to sending the response back to the client. If HeaderModifiers are set on
       both the Destination and the RouteAction, they will be merged. Conflicts
       between the two will not be resolved on the configuration.
       
      .google.cloud.networkservices.v1.HttpRoute.HeaderModifier response_header_modifier = 4 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getResponseHeaderModifierOrBuilder in interface HttpRoute.DestinationOrBuilder
    • 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 HttpRoute.Destination parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

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

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

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

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

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

      public static HttpRoute.Destination parseFrom(InputStream input) throws IOException
      Throws:
      IOException
    • parseFrom

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

      public static HttpRoute.Destination parseDelimitedFrom(InputStream input) throws IOException
      Throws:
      IOException
    • parseDelimitedFrom

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

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

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

      public HttpRoute.Destination.Builder newBuilderForType()
      Specified by:
      newBuilderForType in interface com.google.protobuf.Message
      Specified by:
      newBuilderForType in interface com.google.protobuf.MessageLite
    • newBuilder

      public static HttpRoute.Destination.Builder newBuilder()
    • newBuilder

      public static HttpRoute.Destination.Builder newBuilder(HttpRoute.Destination prototype)
    • toBuilder

      public HttpRoute.Destination.Builder toBuilder()
      Specified by:
      toBuilder in interface com.google.protobuf.Message
      Specified by:
      toBuilder in interface com.google.protobuf.MessageLite
    • newBuilderForType

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

      public static HttpRoute.Destination getDefaultInstance()
    • parser

      public static com.google.protobuf.Parser<HttpRoute.Destination> parser()
    • getParserForType

      public com.google.protobuf.Parser<HttpRoute.Destination> 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 HttpRoute.Destination getDefaultInstanceForType()
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder