Interface RouteBaseProps
- All Superinterfaces:
software.amazon.jsii.JsiiSerializable
- All Known Subinterfaces:
RouteProps
- All Known Implementing Classes:
RouteBaseProps.Jsii$Proxy,RouteProps.Jsii$Proxy
@Generated(value="jsii-pacmak/1.84.0 (build 5404dcf)",
date="2023-06-19T16:30:46.143Z")
@Stability(Stable)
public interface RouteBaseProps
extends software.amazon.jsii.JsiiSerializable
Base interface properties for all Routes.
Example:
VirtualRouter router;
VirtualNode node;
router.addRoute("route-http2-retry", RouteBaseProps.builder()
.routeSpec(RouteSpec.http2(HttpRouteSpecOptions.builder()
.weightedTargets(List.of(WeightedTarget.builder().virtualNode(node).build()))
.retryPolicy(HttpRetryPolicy.builder()
// Retry if the connection failed
.tcpRetryEvents(List.of(TcpRetryEvent.CONNECTION_ERROR))
// Retry if HTTP responds with a gateway error (502, 503, 504)
.httpRetryEvents(List.of(HttpRetryEvent.GATEWAY_ERROR))
// Retry five times
.retryAttempts(5)
// Use a 1 second timeout per retry
.retryTimeout(Duration.seconds(1))
.build())
.build()))
.build());
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic final classA builder forRouteBasePropsstatic final classAn implementation forRouteBaseProps -
Method Summary
Modifier and TypeMethodDescriptionstatic RouteBaseProps.Builderbuilder()default StringThe name of the route.Protocol specific spec.Methods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Method Details
-
getRouteSpec
Protocol specific spec. -
getRouteName
The name of the route.Default: - An automatically generated name
-
builder
- Returns:
- a
RouteBaseProps.BuilderofRouteBaseProps
-