Interface CfnRouteProps

All Superinterfaces:
software.amazon.jsii.JsiiSerializable
All Known Implementing Classes:
CfnRouteProps.Jsii$Proxy

@Generated(value="jsii-pacmak/1.84.0 (build 5404dcf)", date="2023-06-19T16:30:45.869Z") @Stability(Stable) public interface CfnRouteProps extends software.amazon.jsii.JsiiSerializable
Properties for defining a CfnRoute.

Example:

 // The code below shows an example of how to instantiate this type.
 // The values are placeholders you should change.
 import software.amazon.awscdk.services.appmesh.*;
 CfnRouteProps cfnRouteProps = CfnRouteProps.builder()
         .meshName("meshName")
         .spec(RouteSpecProperty.builder()
                 .grpcRoute(GrpcRouteProperty.builder()
                         .action(GrpcRouteActionProperty.builder()
                                 .weightedTargets(List.of(WeightedTargetProperty.builder()
                                         .virtualNode("virtualNode")
                                         .weight(123)
                                         // the properties below are optional
                                         .port(123)
                                         .build()))
                                 .build())
                         .match(GrpcRouteMatchProperty.builder()
                                 .metadata(List.of(GrpcRouteMetadataProperty.builder()
                                         .name("name")
                                         // the properties below are optional
                                         .invert(false)
                                         .match(GrpcRouteMetadataMatchMethodProperty.builder()
                                                 .exact("exact")
                                                 .prefix("prefix")
                                                 .range(MatchRangeProperty.builder()
                                                         .end(123)
                                                         .start(123)
                                                         .build())
                                                 .regex("regex")
                                                 .suffix("suffix")
                                                 .build())
                                         .build()))
                                 .methodName("methodName")
                                 .port(123)
                                 .serviceName("serviceName")
                                 .build())
                         // the properties below are optional
                         .retryPolicy(GrpcRetryPolicyProperty.builder()
                                 .maxRetries(123)
                                 .perRetryTimeout(DurationProperty.builder()
                                         .unit("unit")
                                         .value(123)
                                         .build())
                                 // the properties below are optional
                                 .grpcRetryEvents(List.of("grpcRetryEvents"))
                                 .httpRetryEvents(List.of("httpRetryEvents"))
                                 .tcpRetryEvents(List.of("tcpRetryEvents"))
                                 .build())
                         .timeout(GrpcTimeoutProperty.builder()
                                 .idle(DurationProperty.builder()
                                         .unit("unit")
                                         .value(123)
                                         .build())
                                 .perRequest(DurationProperty.builder()
                                         .unit("unit")
                                         .value(123)
                                         .build())
                                 .build())
                         .build())
                 .http2Route(HttpRouteProperty.builder()
                         .action(HttpRouteActionProperty.builder()
                                 .weightedTargets(List.of(WeightedTargetProperty.builder()
                                         .virtualNode("virtualNode")
                                         .weight(123)
                                         // the properties below are optional
                                         .port(123)
                                         .build()))
                                 .build())
                         .match(HttpRouteMatchProperty.builder()
                                 .headers(List.of(HttpRouteHeaderProperty.builder()
                                         .name("name")
                                         // the properties below are optional
                                         .invert(false)
                                         .match(HeaderMatchMethodProperty.builder()
                                                 .exact("exact")
                                                 .prefix("prefix")
                                                 .range(MatchRangeProperty.builder()
                                                         .end(123)
                                                         .start(123)
                                                         .build())
                                                 .regex("regex")
                                                 .suffix("suffix")
                                                 .build())
                                         .build()))
                                 .method("method")
                                 .path(HttpPathMatchProperty.builder()
                                         .exact("exact")
                                         .regex("regex")
                                         .build())
                                 .port(123)
                                 .prefix("prefix")
                                 .queryParameters(List.of(QueryParameterProperty.builder()
                                         .name("name")
                                         // the properties below are optional
                                         .match(HttpQueryParameterMatchProperty.builder()
                                                 .exact("exact")
                                                 .build())
                                         .build()))
                                 .scheme("scheme")
                                 .build())
                         // the properties below are optional
                         .retryPolicy(HttpRetryPolicyProperty.builder()
                                 .maxRetries(123)
                                 .perRetryTimeout(DurationProperty.builder()
                                         .unit("unit")
                                         .value(123)
                                         .build())
                                 // the properties below are optional
                                 .httpRetryEvents(List.of("httpRetryEvents"))
                                 .tcpRetryEvents(List.of("tcpRetryEvents"))
                                 .build())
                         .timeout(HttpTimeoutProperty.builder()
                                 .idle(DurationProperty.builder()
                                         .unit("unit")
                                         .value(123)
                                         .build())
                                 .perRequest(DurationProperty.builder()
                                         .unit("unit")
                                         .value(123)
                                         .build())
                                 .build())
                         .build())
                 .httpRoute(HttpRouteProperty.builder()
                         .action(HttpRouteActionProperty.builder()
                                 .weightedTargets(List.of(WeightedTargetProperty.builder()
                                         .virtualNode("virtualNode")
                                         .weight(123)
                                         // the properties below are optional
                                         .port(123)
                                         .build()))
                                 .build())
                         .match(HttpRouteMatchProperty.builder()
                                 .headers(List.of(HttpRouteHeaderProperty.builder()
                                         .name("name")
                                         // the properties below are optional
                                         .invert(false)
                                         .match(HeaderMatchMethodProperty.builder()
                                                 .exact("exact")
                                                 .prefix("prefix")
                                                 .range(MatchRangeProperty.builder()
                                                         .end(123)
                                                         .start(123)
                                                         .build())
                                                 .regex("regex")
                                                 .suffix("suffix")
                                                 .build())
                                         .build()))
                                 .method("method")
                                 .path(HttpPathMatchProperty.builder()
                                         .exact("exact")
                                         .regex("regex")
                                         .build())
                                 .port(123)
                                 .prefix("prefix")
                                 .queryParameters(List.of(QueryParameterProperty.builder()
                                         .name("name")
                                         // the properties below are optional
                                         .match(HttpQueryParameterMatchProperty.builder()
                                                 .exact("exact")
                                                 .build())
                                         .build()))
                                 .scheme("scheme")
                                 .build())
                         // the properties below are optional
                         .retryPolicy(HttpRetryPolicyProperty.builder()
                                 .maxRetries(123)
                                 .perRetryTimeout(DurationProperty.builder()
                                         .unit("unit")
                                         .value(123)
                                         .build())
                                 // the properties below are optional
                                 .httpRetryEvents(List.of("httpRetryEvents"))
                                 .tcpRetryEvents(List.of("tcpRetryEvents"))
                                 .build())
                         .timeout(HttpTimeoutProperty.builder()
                                 .idle(DurationProperty.builder()
                                         .unit("unit")
                                         .value(123)
                                         .build())
                                 .perRequest(DurationProperty.builder()
                                         .unit("unit")
                                         .value(123)
                                         .build())
                                 .build())
                         .build())
                 .priority(123)
                 .tcpRoute(TcpRouteProperty.builder()
                         .action(TcpRouteActionProperty.builder()
                                 .weightedTargets(List.of(WeightedTargetProperty.builder()
                                         .virtualNode("virtualNode")
                                         .weight(123)
                                         // the properties below are optional
                                         .port(123)
                                         .build()))
                                 .build())
                         // the properties below are optional
                         .match(TcpRouteMatchProperty.builder()
                                 .port(123)
                                 .build())
                         .timeout(TcpTimeoutProperty.builder()
                                 .idle(DurationProperty.builder()
                                         .unit("unit")
                                         .value(123)
                                         .build())
                                 .build())
                         .build())
                 .build())
         .virtualRouterName("virtualRouterName")
         // the properties below are optional
         .meshOwner("meshOwner")
         .routeName("routeName")
         .tags(List.of(CfnTag.builder()
                 .key("key")
                 .value("value")
                 .build()))
         .build();
 
  • Method Details

    • getMeshName

      @Stability(Stable) @NotNull String getMeshName()
      The name of the service mesh to create the route in.
    • getSpec

      @Stability(Stable) @NotNull Object getSpec()
      The route specification to apply.
    • getVirtualRouterName

      @Stability(Stable) @NotNull String getVirtualRouterName()
      The name of the virtual router in which to create the route.

      If the virtual router is in a shared mesh, then you must be the owner of the virtual router resource.

    • getMeshOwner

      @Stability(Stable) @Nullable default String getMeshOwner()
      The AWS IAM account ID of the service mesh owner.

      If the account ID is not your own, then the account that you specify must share the mesh with your account before you can create the resource in the service mesh. For more information about mesh sharing, see Working with shared meshes .

    • getRouteName

      @Stability(Stable) @Nullable default String getRouteName()
      The name to use for the route.
    • getTags

      @Stability(Stable) @Nullable default List<CfnTag> getTags()
      Optional metadata that you can apply to the route to assist with categorization and organization.

      Each tag consists of a key and an optional value, both of which you define. Tag keys can have a maximum character length of 128 characters, and tag values can have a maximum length of 256 characters.

    • builder

      @Stability(Stable) static CfnRouteProps.Builder builder()
      Returns:
      a CfnRouteProps.Builder of CfnRouteProps