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.
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.
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.
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.
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.
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.
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.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-16 UTC."],[],[],null,["# Interface HttpRoute.DestinationOrBuilder (0.28.0)\n\nVersion latestkeyboard_arrow_down\n\n- [0.28.0 (latest)](/java/docs/reference/google-cloud-networkservices/latest/com.google.cloud.networkservices.v1.HttpRoute.DestinationOrBuilder)\n- [0.26.0](/java/docs/reference/google-cloud-networkservices/0.26.0/com.google.cloud.networkservices.v1.HttpRoute.DestinationOrBuilder)\n- [0.24.0](/java/docs/reference/google-cloud-networkservices/0.24.0/com.google.cloud.networkservices.v1.HttpRoute.DestinationOrBuilder)\n- [0.23.0](/java/docs/reference/google-cloud-networkservices/0.23.0/com.google.cloud.networkservices.v1.HttpRoute.DestinationOrBuilder)\n- [0.20.0](/java/docs/reference/google-cloud-networkservices/0.20.0/com.google.cloud.networkservices.v1.HttpRoute.DestinationOrBuilder)\n- [0.19.0](/java/docs/reference/google-cloud-networkservices/0.19.0/com.google.cloud.networkservices.v1.HttpRoute.DestinationOrBuilder)\n- [0.18.0](/java/docs/reference/google-cloud-networkservices/0.18.0/com.google.cloud.networkservices.v1.HttpRoute.DestinationOrBuilder)\n- [0.16.0](/java/docs/reference/google-cloud-networkservices/0.16.0/com.google.cloud.networkservices.v1.HttpRoute.DestinationOrBuilder)\n- [0.15.0](/java/docs/reference/google-cloud-networkservices/0.15.0/com.google.cloud.networkservices.v1.HttpRoute.DestinationOrBuilder)\n- [0.14.0](/java/docs/reference/google-cloud-networkservices/0.14.0/com.google.cloud.networkservices.v1.HttpRoute.DestinationOrBuilder)\n- [0.13.0](/java/docs/reference/google-cloud-networkservices/0.13.0/com.google.cloud.networkservices.v1.HttpRoute.DestinationOrBuilder)\n- [0.12.0](/java/docs/reference/google-cloud-networkservices/0.12.0/com.google.cloud.networkservices.v1.HttpRoute.DestinationOrBuilder)\n- [0.11.0](/java/docs/reference/google-cloud-networkservices/0.11.0/com.google.cloud.networkservices.v1.HttpRoute.DestinationOrBuilder)\n- [0.10.0](/java/docs/reference/google-cloud-networkservices/0.10.0/com.google.cloud.networkservices.v1.HttpRoute.DestinationOrBuilder)\n- [0.9.0](/java/docs/reference/google-cloud-networkservices/0.9.0/com.google.cloud.networkservices.v1.HttpRoute.DestinationOrBuilder)\n- [0.8.0](/java/docs/reference/google-cloud-networkservices/0.8.0/com.google.cloud.networkservices.v1.HttpRoute.DestinationOrBuilder)\n- [0.7.0](/java/docs/reference/google-cloud-networkservices/0.7.0/com.google.cloud.networkservices.v1.HttpRoute.DestinationOrBuilder)\n- [0.5.0](/java/docs/reference/google-cloud-networkservices/0.5.0/com.google.cloud.networkservices.v1.HttpRoute.DestinationOrBuilder)\n- [0.4.0](/java/docs/reference/google-cloud-networkservices/0.4.0/com.google.cloud.networkservices.v1.HttpRoute.DestinationOrBuilder)\n- [0.3.0](/java/docs/reference/google-cloud-networkservices/0.3.0/com.google.cloud.networkservices.v1.HttpRoute.DestinationOrBuilder)\n- [0.2.0](/java/docs/reference/google-cloud-networkservices/0.2.0/com.google.cloud.networkservices.v1.HttpRoute.DestinationOrBuilder)\n- [0.1.0](/java/docs/reference/google-cloud-networkservices/0.1.0/com.google.cloud.networkservices.v1.HttpRoute.DestinationOrBuilder) \n\n public static interface HttpRoute.DestinationOrBuilder extends MessageOrBuilder\n\nImplements\n----------\n\n[MessageOrBuilder](https://cloud.google.com/java/docs/reference/protobuf/latest/com.google.protobuf.MessageOrBuilder.html)\n\nMethods\n-------\n\n### getRequestHeaderModifier()\n\n public abstract HttpRoute.HeaderModifier getRequestHeaderModifier()\n\nOptional. The specification for modifying the headers of a matching\nrequest prior to delivery of the request to the destination. If\nHeaderModifiers are set on both the Destination and the RouteAction, they\nwill be merged. Conflicts between the two will not be resolved on the\nconfiguration.\n\n`\n.google.cloud.networkservices.v1.HttpRoute.HeaderModifier request_header_modifier = 3 [(.google.api.field_behavior) = OPTIONAL];\n`\n\n### getRequestHeaderModifierOrBuilder()\n\n public abstract HttpRoute.HeaderModifierOrBuilder getRequestHeaderModifierOrBuilder()\n\nOptional. The specification for modifying the headers of a matching\nrequest prior to delivery of the request to the destination. If\nHeaderModifiers are set on both the Destination and the RouteAction, they\nwill be merged. Conflicts between the two will not be resolved on the\nconfiguration.\n\n`\n.google.cloud.networkservices.v1.HttpRoute.HeaderModifier request_header_modifier = 3 [(.google.api.field_behavior) = OPTIONAL];\n`\n\n### getResponseHeaderModifier()\n\n public abstract HttpRoute.HeaderModifier getResponseHeaderModifier()\n\nOptional. The specification for modifying the headers of a response prior\nto sending the response back to the client. If HeaderModifiers are set on\nboth the Destination and the RouteAction, they will be merged. Conflicts\nbetween the two will not be resolved on the configuration.\n\n`\n.google.cloud.networkservices.v1.HttpRoute.HeaderModifier response_header_modifier = 4 [(.google.api.field_behavior) = OPTIONAL];\n`\n\n### getResponseHeaderModifierOrBuilder()\n\n public abstract HttpRoute.HeaderModifierOrBuilder getResponseHeaderModifierOrBuilder()\n\nOptional. The specification for modifying the headers of a response prior\nto sending the response back to the client. If HeaderModifiers are set on\nboth the Destination and the RouteAction, they will be merged. Conflicts\nbetween the two will not be resolved on the configuration.\n\n`\n.google.cloud.networkservices.v1.HttpRoute.HeaderModifier response_header_modifier = 4 [(.google.api.field_behavior) = OPTIONAL];\n`\n\n### getServiceName()\n\n public abstract String getServiceName()\n\nThe URL of a BackendService to route traffic to.\n\n`string service_name = 1 [(.google.api.resource_reference) = { ... }`\n\n### getServiceNameBytes()\n\n public abstract ByteString getServiceNameBytes()\n\nThe URL of a BackendService to route traffic to.\n\n`string service_name = 1 [(.google.api.resource_reference) = { ... }`\n\n### getWeight()\n\n public abstract int getWeight()\n\nSpecifies the proportion of requests forwarded to the backend referenced\nby the serviceName field. This is computed as:\n\n- weight/Sum(weights in this destination list).\n For non-zero values, there may be some epsilon from the exact proportion\n defined here depending on the precision an implementation supports.\n\n If only one serviceName is specified and it has a weight greater than 0,\n 100% of the traffic is forwarded to that backend.\n\n If weights are specified for any one service name, they need to be\n specified for all of them.\n\n If weights are unspecified for all services, then, traffic is distributed\n in equal proportions to all of them.\n\n`int32 weight = 2;`\n\n### hasRequestHeaderModifier()\n\n public abstract boolean hasRequestHeaderModifier()\n\nOptional. The specification for modifying the headers of a matching\nrequest prior to delivery of the request to the destination. If\nHeaderModifiers are set on both the Destination and the RouteAction, they\nwill be merged. Conflicts between the two will not be resolved on the\nconfiguration.\n\n`\n.google.cloud.networkservices.v1.HttpRoute.HeaderModifier request_header_modifier = 3 [(.google.api.field_behavior) = OPTIONAL];\n`\n\n### hasResponseHeaderModifier()\n\n public abstract boolean hasResponseHeaderModifier()\n\nOptional. The specification for modifying the headers of a response prior\nto sending the response back to the client. If HeaderModifiers are set on\nboth the Destination and the RouteAction, they will be merged. Conflicts\nbetween the two will not be resolved on the configuration.\n\n`\n.google.cloud.networkservices.v1.HttpRoute.HeaderModifier response_header_modifier = 4 [(.google.api.field_behavior) = OPTIONAL];\n`"]]