aws-cdk-lib.aws_appmesh.CfnGatewayRoute.HttpGatewayRouteActionProperty

interface HttpGatewayRouteActionProperty

LanguageType name
.NETAmazon.CDK.AWS.AppMesh.CfnGatewayRoute.HttpGatewayRouteActionProperty
Gogithub.com/aws/aws-cdk-go/awscdk/v2/awsappmesh#CfnGatewayRoute_HttpGatewayRouteActionProperty
Javasoftware.amazon.awscdk.services.appmesh.CfnGatewayRoute.HttpGatewayRouteActionProperty
Pythonaws_cdk.aws_appmesh.CfnGatewayRoute.HttpGatewayRouteActionProperty
TypeScript aws-cdk-lib » aws_appmesh » CfnGatewayRoute » HttpGatewayRouteActionProperty

An object that represents the action to take if a match is determined.

Example

// 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 httpGatewayRouteActionProperty: appmesh.CfnGatewayRoute.HttpGatewayRouteActionProperty = {
  target: {
    virtualService: {
      virtualServiceName: 'virtualServiceName',
    },

    // the properties below are optional
    port: 123,
  },

  // the properties below are optional
  rewrite: {
    hostname: {
      defaultTargetHostname: 'defaultTargetHostname',
    },
    path: {
      exact: 'exact',
    },
    prefix: {
      defaultPrefix: 'defaultPrefix',
      value: 'value',
    },
  },
};

Properties

NameTypeDescription
targetIResolvable | GatewayRouteTargetPropertyAn object that represents the target that traffic is routed to when a request matches the gateway route.
rewrite?IResolvable | HttpGatewayRouteRewritePropertyThe gateway route action to rewrite.

target

Type: IResolvable | GatewayRouteTargetProperty

An object that represents the target that traffic is routed to when a request matches the gateway route.


rewrite?

Type: IResolvable | HttpGatewayRouteRewriteProperty (optional)

The gateway route action to rewrite.