aws-cdk-lib.aws_appmesh.GatewayRouteSpecConfig

interface GatewayRouteSpecConfig

LanguageType name
.NETAmazon.CDK.AWS.AppMesh.GatewayRouteSpecConfig
Gogithub.com/aws/aws-cdk-go/awscdk/v2/awsappmesh#GatewayRouteSpecConfig
Javasoftware.amazon.awscdk.services.appmesh.GatewayRouteSpecConfig
Pythonaws_cdk.aws_appmesh.GatewayRouteSpecConfig
TypeScript (source)aws-cdk-lib » aws_appmesh » GatewayRouteSpecConfig

Obtainable from GatewayRouteSpec.bind()

All Properties for GatewayRoute Specs.

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 gatewayRouteSpecConfig: appmesh.GatewayRouteSpecConfig = {
  grpcSpecConfig: {
    action: {
      target: {
        virtualService: {
          virtualServiceName: 'virtualServiceName',
        },

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

      // the properties below are optional
      rewrite: {
        hostname: {
          defaultTargetHostname: 'defaultTargetHostname',
        },
      },
    },
    match: {
      hostname: {
        exact: 'exact',
        suffix: 'suffix',
      },
      metadata: [{
        name: 'name',

        // the properties below are optional
        invert: false,
        match: {
          exact: 'exact',
          prefix: 'prefix',
          range: {
            end: 123,
            start: 123,
          },
          regex: 'regex',
          suffix: 'suffix',
        },
      }],
      port: 123,
      serviceName: 'serviceName',
    },
  },
  http2SpecConfig: {
    action: {
      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',
        },
      },
    },
    match: {
      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',
        },
      }],
    },
  },
  httpSpecConfig: {
    action: {
      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',
        },
      },
    },
    match: {
      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',
        },
      }],
    },
  },
  priority: 123,
};

Properties

NameTypeDescription
grpcSpecConfig?GrpcGatewayRoutePropertyThe spec for a grpc gateway route.
http2SpecConfig?HttpGatewayRoutePropertyThe spec for an http2 gateway route.
httpSpecConfig?HttpGatewayRoutePropertyThe spec for an http gateway route.
priority?numberThe priority for the gateway route.

grpcSpecConfig?

Type: GrpcGatewayRouteProperty (optional, default: no grpc spec)

The spec for a grpc gateway route.


http2SpecConfig?

Type: HttpGatewayRouteProperty (optional, default: no http2 spec)

The spec for an http2 gateway route.


httpSpecConfig?

Type: HttpGatewayRouteProperty (optional, default: no http spec)

The spec for an http gateway route.


priority?

Type: number (optional, default: no particular priority)

The priority for the gateway route.

When a Virtual Gateway has multiple gateway routes, gateway route match is performed in the order of specified value, where 0 is the highest priority, and first matched gateway route is selected.