aws-cdk-lib.aws_appmesh.CfnGatewayRoute.HttpGatewayRouteMatchProperty

interface HttpGatewayRouteMatchProperty

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

An object that represents the criteria for determining a request match.

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 httpGatewayRouteMatchProperty: appmesh.CfnGatewayRoute.HttpGatewayRouteMatchProperty = {
  headers: [{
    name: 'name',

    // the properties below are optional
    invert: false,
    match: {
      exact: 'exact',
      prefix: 'prefix',
      range: {
        end: 123,
        start: 123,
      },
      regex: 'regex',
      suffix: 'suffix',
    },
  }],
  hostname: {
    exact: 'exact',
    suffix: 'suffix',
  },
  method: 'method',
  path: {
    exact: 'exact',
    regex: 'regex',
  },
  port: 123,
  prefix: 'prefix',
  queryParameters: [{
    name: 'name',

    // the properties below are optional
    match: {
      exact: 'exact',
    },
  }],
};

Properties

NameTypeDescription
headers?IResolvable | IResolvable | HttpGatewayRouteHeaderProperty[]The client request headers to match on.
hostname?IResolvable | GatewayRouteHostnameMatchPropertyThe host name to match on.
method?stringThe method to match on.
path?IResolvable | HttpPathMatchPropertyThe path to match on.
port?numberThe port number to match on.
prefix?stringSpecifies the path to match requests with.
queryParameters?IResolvable | IResolvable | QueryParameterProperty[]The query parameter to match on.

headers?

Type: IResolvable | IResolvable | HttpGatewayRouteHeaderProperty[] (optional)

The client request headers to match on.


hostname?

Type: IResolvable | GatewayRouteHostnameMatchProperty (optional)

The host name to match on.


method?

Type: string (optional)

The method to match on.


path?

Type: IResolvable | HttpPathMatchProperty (optional)

The path to match on.


port?

Type: number (optional)

The port number to match on.


prefix?

Type: string (optional)

Specifies the path to match requests with.

This parameter must always start with / , which by itself matches all requests to the virtual service name. You can also match for path-based routing of requests. For example, if your virtual service name is my-service.local and you want the route to match requests to my-service.local/metrics , your prefix should be /metrics .


queryParameters?

Type: IResolvable | IResolvable | QueryParameterProperty[] (optional)

The query parameter to match on.