Skip to content
v2.278.0

HttpGatewayRouteRewriteProperty Struct ​

An object representing the gateway route to rewrite.

Example ​

ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_appmesh as appmesh } from 'aws-cdk-lib';
const httpGatewayRouteRewriteProperty: appmesh.CfnGatewayRoute.HttpGatewayRouteRewriteProperty = {
  hostname: {
    defaultTargetHostname: 'defaultTargetHostname',
  },
  path: {
    exact: 'exact',
  },
  prefix: {
    defaultPrefix: 'defaultPrefix',
    value: 'value',
  },
};
python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_appmesh as appmesh

http_gateway_route_rewrite_property = appmesh.CfnGatewayRoute.HttpGatewayRouteRewriteProperty(
    hostname=appmesh.CfnGatewayRoute.GatewayRouteHostnameRewriteProperty(
        default_target_hostname="defaultTargetHostname"
    ),
    path=appmesh.CfnGatewayRoute.HttpGatewayRoutePathRewriteProperty(
        exact="exact"
    ),
    prefix=appmesh.CfnGatewayRoute.HttpGatewayRoutePrefixRewriteProperty(
        default_prefix="defaultPrefix",
        value="value"
    )
)
java
// 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.*;

HttpGatewayRouteRewriteProperty httpGatewayRouteRewriteProperty = HttpGatewayRouteRewriteProperty.builder()
        .hostname(GatewayRouteHostnameRewriteProperty.builder()
                .defaultTargetHostname("defaultTargetHostname")
                .build())
        .path(HttpGatewayRoutePathRewriteProperty.builder()
                .exact("exact")
                .build())
        .prefix(HttpGatewayRoutePrefixRewriteProperty.builder()
                .defaultPrefix("defaultPrefix")
                .value("value")
                .build())
        .build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.AppMesh;

var httpGatewayRouteRewriteProperty = new HttpGatewayRouteRewriteProperty {
    Hostname = new GatewayRouteHostnameRewriteProperty {
        DefaultTargetHostname = "defaultTargetHostname"
    },
    Path = new HttpGatewayRoutePathRewriteProperty {
        Exact = "exact"
    },
    Prefix = new HttpGatewayRoutePrefixRewriteProperty {
        DefaultPrefix = "defaultPrefix",
        Value = "value"
    }
};
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"

httpGatewayRouteRewriteProperty := &HttpGatewayRouteRewriteProperty{
	Hostname: &GatewayRouteHostnameRewriteProperty{
		DefaultTargetHostname: jsii.String("defaultTargetHostname"),
	},
	Path: &HttpGatewayRoutePathRewriteProperty{
		Exact: jsii.String("exact"),
	},
	Prefix: &HttpGatewayRoutePrefixRewriteProperty{
		DefaultPrefix: jsii.String("defaultPrefix"),
		Value: jsii.String("value"),
	},
}

Properties ​

hostnameoptionalIResolvable | CfnGatewayRoute.GatewayRouteHostnameRewritePropertyhostnameoptionaltyping.Union[IResolvable, GatewayRouteHostnameRewriteProperty]hostnameoptionalIResolvableHostnameoptionalIResolvableHostnameoptionalinterface{} #
The host name to rewrite.
pathoptionalIResolvable | CfnGatewayRoute.HttpGatewayRoutePathRewritePropertypathoptionaltyping.Union[IResolvable, HttpGatewayRoutePathRewriteProperty]pathoptionalIResolvablePathoptionalIResolvablePathoptionalinterface{} #
The path to rewrite.
prefixoptionalIResolvable | CfnGatewayRoute.HttpGatewayRoutePrefixRewritePropertyprefixoptionaltyping.Union[IResolvable, HttpGatewayRoutePrefixRewriteProperty]prefixoptionalIResolvablePrefixoptionalIResolvablePrefixoptionalinterface{} #
The specified beginning characters to rewrite.