aws-cdk-lib.aws_appmesh.VirtualRouterProps

interface VirtualRouterProps

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

The properties used when creating a new VirtualRouter.

Example

declare const infraStack: cdk.Stack;
declare const appStack: cdk.Stack;

const mesh = new appmesh.Mesh(infraStack, 'AppMesh', {
  meshName: 'myAwsMesh',
  egressFilter: appmesh.MeshFilterType.ALLOW_ALL,
});

// the VirtualRouter will belong to 'appStack',
// even though the Mesh belongs to 'infraStack'
const router = new appmesh.VirtualRouter(appStack, 'router', {
  mesh, // notice that mesh is a required property when creating a router with the 'new' statement
  listeners: [appmesh.VirtualRouterListener.http(8081)],
});

Properties

NameTypeDescription
meshIMeshThe Mesh which the VirtualRouter belongs to.
listeners?VirtualRouterListener[]Listener specification for the VirtualRouter.
virtualRouterName?stringThe name of the VirtualRouter.

mesh

Type: IMesh

The Mesh which the VirtualRouter belongs to.


listeners?

Type: VirtualRouterListener[] (optional, default: A listener on HTTP port 8080)

Listener specification for the VirtualRouter.


virtualRouterName?

Type: string (optional, default: A name is automatically determined)

The name of the VirtualRouter.