Package com.google.cloud.compute.v1
Interface PathRuleOrBuilder
- All Superinterfaces:
com.google.protobuf.MessageLiteOrBuilder,com.google.protobuf.MessageOrBuilder
- All Known Implementing Classes:
PathRule,PathRule.Builder
@Generated
public interface PathRuleOrBuilder
extends com.google.protobuf.MessageOrBuilder
-
Method Summary
Modifier and TypeMethodDescriptioncustomErrorResponsePolicy specifies how the Load Balancer returns error responses when BackendServiceorBackendBucket responds with an error.customErrorResponsePolicy specifies how the Load Balancer returns error responses when BackendServiceorBackendBucket responds with an error.getPaths(int index) The list of path patterns to match.com.google.protobuf.ByteStringgetPathsBytes(int index) The list of path patterns to match.intThe list of path patterns to match.The list of path patterns to match.In response to a matching path, the load balancer performs advanced routing actions, such as URL rewrites and header transformations, before forwarding the request to the selected backend.In response to a matching path, the load balancer performs advanced routing actions, such as URL rewrites and header transformations, before forwarding the request to the selected backend.The full or partial URL of the backend service resource to which traffic is directed if this rule is matched.com.google.protobuf.ByteStringThe full or partial URL of the backend service resource to which traffic is directed if this rule is matched.When a path pattern is matched, the request is redirected to a URL specified by urlRedirect.When a path pattern is matched, the request is redirected to a URL specified by urlRedirect.booleancustomErrorResponsePolicy specifies how the Load Balancer returns error responses when BackendServiceorBackendBucket responds with an error.booleanIn response to a matching path, the load balancer performs advanced routing actions, such as URL rewrites and header transformations, before forwarding the request to the selected backend.booleanThe full or partial URL of the backend service resource to which traffic is directed if this rule is matched.booleanWhen a path pattern is matched, the request is redirected to a URL specified by urlRedirect.Methods inherited from interface com.google.protobuf.MessageLiteOrBuilder
isInitializedMethods inherited from interface com.google.protobuf.MessageOrBuilder
findInitializationErrors, getAllFields, getDefaultInstanceForType, getDescriptorForType, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
-
Method Details
-
hasCustomErrorResponsePolicy
boolean hasCustomErrorResponsePolicy()customErrorResponsePolicy specifies how the Load Balancer returns error responses when BackendServiceorBackendBucket responds with an error. If a policy for an error code is not configured for the PathRule, a policy for the error code configured inpathMatcher.defaultCustomErrorResponsePolicy is applied. If one is not specified inpathMatcher.defaultCustomErrorResponsePolicy, the policy configured in UrlMap.defaultCustomErrorResponsePolicy takes effect. For example, consider a UrlMap with the following configuration: - UrlMap.defaultCustomErrorResponsePolicy are configured with policies for 5xx and 4xx errors - A PathRule for /coming_soon/ is configured for the error code 404. If the request is for www.myotherdomain.com and a404 is encountered, the policy underUrlMap.defaultCustomErrorResponsePolicy takes effect. If a404 response is encountered for the requestwww.example.com/current_events/, the pathMatcher's policy takes effect. If however, the request forwww.example.com/coming_soon/ encounters a 404, the policy in PathRule.customErrorResponsePolicy takes effect. If any of the requests in this example encounter a 500 error code, the policy atUrlMap.defaultCustomErrorResponsePolicy takes effect. customErrorResponsePolicy is supported only for global external Application Load Balancers.
optional .google.cloud.compute.v1.CustomErrorResponsePolicy custom_error_response_policy = 202816619;- Returns:
- Whether the customErrorResponsePolicy field is set.
-
getCustomErrorResponsePolicy
CustomErrorResponsePolicy getCustomErrorResponsePolicy()customErrorResponsePolicy specifies how the Load Balancer returns error responses when BackendServiceorBackendBucket responds with an error. If a policy for an error code is not configured for the PathRule, a policy for the error code configured inpathMatcher.defaultCustomErrorResponsePolicy is applied. If one is not specified inpathMatcher.defaultCustomErrorResponsePolicy, the policy configured in UrlMap.defaultCustomErrorResponsePolicy takes effect. For example, consider a UrlMap with the following configuration: - UrlMap.defaultCustomErrorResponsePolicy are configured with policies for 5xx and 4xx errors - A PathRule for /coming_soon/ is configured for the error code 404. If the request is for www.myotherdomain.com and a404 is encountered, the policy underUrlMap.defaultCustomErrorResponsePolicy takes effect. If a404 response is encountered for the requestwww.example.com/current_events/, the pathMatcher's policy takes effect. If however, the request forwww.example.com/coming_soon/ encounters a 404, the policy in PathRule.customErrorResponsePolicy takes effect. If any of the requests in this example encounter a 500 error code, the policy atUrlMap.defaultCustomErrorResponsePolicy takes effect. customErrorResponsePolicy is supported only for global external Application Load Balancers.
optional .google.cloud.compute.v1.CustomErrorResponsePolicy custom_error_response_policy = 202816619;- Returns:
- The customErrorResponsePolicy.
-
getCustomErrorResponsePolicyOrBuilder
CustomErrorResponsePolicyOrBuilder getCustomErrorResponsePolicyOrBuilder()customErrorResponsePolicy specifies how the Load Balancer returns error responses when BackendServiceorBackendBucket responds with an error. If a policy for an error code is not configured for the PathRule, a policy for the error code configured inpathMatcher.defaultCustomErrorResponsePolicy is applied. If one is not specified inpathMatcher.defaultCustomErrorResponsePolicy, the policy configured in UrlMap.defaultCustomErrorResponsePolicy takes effect. For example, consider a UrlMap with the following configuration: - UrlMap.defaultCustomErrorResponsePolicy are configured with policies for 5xx and 4xx errors - A PathRule for /coming_soon/ is configured for the error code 404. If the request is for www.myotherdomain.com and a404 is encountered, the policy underUrlMap.defaultCustomErrorResponsePolicy takes effect. If a404 response is encountered for the requestwww.example.com/current_events/, the pathMatcher's policy takes effect. If however, the request forwww.example.com/coming_soon/ encounters a 404, the policy in PathRule.customErrorResponsePolicy takes effect. If any of the requests in this example encounter a 500 error code, the policy atUrlMap.defaultCustomErrorResponsePolicy takes effect. customErrorResponsePolicy is supported only for global external Application Load Balancers.
optional .google.cloud.compute.v1.CustomErrorResponsePolicy custom_error_response_policy = 202816619; -
getPathsList
The list of path patterns to match. Each must start with / and the only place a * is allowed is at the end following a /. The string fed to the path matcher does not include any text after the first ? or #, and those chars are not allowed here.
repeated string paths = 106438894;- Returns:
- A list containing the paths.
-
getPathsCount
int getPathsCount()The list of path patterns to match. Each must start with / and the only place a * is allowed is at the end following a /. The string fed to the path matcher does not include any text after the first ? or #, and those chars are not allowed here.
repeated string paths = 106438894;- Returns:
- The count of paths.
-
getPaths
The list of path patterns to match. Each must start with / and the only place a * is allowed is at the end following a /. The string fed to the path matcher does not include any text after the first ? or #, and those chars are not allowed here.
repeated string paths = 106438894;- Parameters:
index- The index of the element to return.- Returns:
- The paths at the given index.
-
getPathsBytes
com.google.protobuf.ByteString getPathsBytes(int index) The list of path patterns to match. Each must start with / and the only place a * is allowed is at the end following a /. The string fed to the path matcher does not include any text after the first ? or #, and those chars are not allowed here.
repeated string paths = 106438894;- Parameters:
index- The index of the value to return.- Returns:
- The bytes of the paths at the given index.
-
hasRouteAction
boolean hasRouteAction()In response to a matching path, the load balancer performs advanced routing actions, such as URL rewrites and header transformations, before forwarding the request to the selected backend. Only one of urlRedirect, service orrouteAction.weightedBackendService can be set. URL maps for classic Application Load Balancers only support the urlRewrite action within a path rule'srouteAction.
optional .google.cloud.compute.v1.HttpRouteAction route_action = 424563948;- Returns:
- Whether the routeAction field is set.
-
getRouteAction
HttpRouteAction getRouteAction()In response to a matching path, the load balancer performs advanced routing actions, such as URL rewrites and header transformations, before forwarding the request to the selected backend. Only one of urlRedirect, service orrouteAction.weightedBackendService can be set. URL maps for classic Application Load Balancers only support the urlRewrite action within a path rule'srouteAction.
optional .google.cloud.compute.v1.HttpRouteAction route_action = 424563948;- Returns:
- The routeAction.
-
getRouteActionOrBuilder
HttpRouteActionOrBuilder getRouteActionOrBuilder()In response to a matching path, the load balancer performs advanced routing actions, such as URL rewrites and header transformations, before forwarding the request to the selected backend. Only one of urlRedirect, service orrouteAction.weightedBackendService can be set. URL maps for classic Application Load Balancers only support the urlRewrite action within a path rule'srouteAction.
optional .google.cloud.compute.v1.HttpRouteAction route_action = 424563948; -
hasService
boolean hasService()The full or partial URL of the backend service resource to which traffic is directed if this rule is matched. If routeAction is also specified, advanced routing actions, such as URL rewrites, take effect before sending the request to the backend. Only one of urlRedirect, service orrouteAction.weightedBackendService can be set.
optional string service = 373540533;- Returns:
- Whether the service field is set.
-
getService
String getService()The full or partial URL of the backend service resource to which traffic is directed if this rule is matched. If routeAction is also specified, advanced routing actions, such as URL rewrites, take effect before sending the request to the backend. Only one of urlRedirect, service orrouteAction.weightedBackendService can be set.
optional string service = 373540533;- Returns:
- The service.
-
getServiceBytes
com.google.protobuf.ByteString getServiceBytes()The full or partial URL of the backend service resource to which traffic is directed if this rule is matched. If routeAction is also specified, advanced routing actions, such as URL rewrites, take effect before sending the request to the backend. Only one of urlRedirect, service orrouteAction.weightedBackendService can be set.
optional string service = 373540533;- Returns:
- The bytes for service.
-
hasUrlRedirect
boolean hasUrlRedirect()When a path pattern is matched, the request is redirected to a URL specified by urlRedirect. Only one of urlRedirect, service orrouteAction.weightedBackendService can be set. Not supported when the URL map is bound to a target gRPC proxy.
optional .google.cloud.compute.v1.HttpRedirectAction url_redirect = 405147820;- Returns:
- Whether the urlRedirect field is set.
-
getUrlRedirect
HttpRedirectAction getUrlRedirect()When a path pattern is matched, the request is redirected to a URL specified by urlRedirect. Only one of urlRedirect, service orrouteAction.weightedBackendService can be set. Not supported when the URL map is bound to a target gRPC proxy.
optional .google.cloud.compute.v1.HttpRedirectAction url_redirect = 405147820;- Returns:
- The urlRedirect.
-
getUrlRedirectOrBuilder
HttpRedirectActionOrBuilder getUrlRedirectOrBuilder()When a path pattern is matched, the request is redirected to a URL specified by urlRedirect. Only one of urlRedirect, service orrouteAction.weightedBackendService can be set. Not supported when the URL map is bound to a target gRPC proxy.
optional .google.cloud.compute.v1.HttpRedirectAction url_redirect = 405147820;
-