Skip to content
v2.278.0

VirtualGatewayListenerProperty Struct ​

An object that represents a listener for a virtual gateway.

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 virtualGatewayListenerProperty: appmesh.CfnVirtualGateway.VirtualGatewayListenerProperty = {
  portMapping: {
    port: 123,
    protocol: 'protocol',
  },

  // the properties below are optional
  connectionPool: {
    grpc: {
      maxRequests: 123,
    },
    http: {
      maxConnections: 123,

      // the properties below are optional
      maxPendingRequests: 123,
    },
    http2: {
      maxRequests: 123,
    },
  },
  healthCheck: {
    healthyThreshold: 123,
    intervalMillis: 123,
    protocol: 'protocol',
    timeoutMillis: 123,
    unhealthyThreshold: 123,

    // the properties below are optional
    path: 'path',
    port: 123,
  },
  tls: {
    certificate: {
      acm: {
        certificateArn: 'certificateArn',
      },
      file: {
        certificateChain: 'certificateChain',
        privateKey: 'privateKey',
      },
      sds: {
        secretName: 'secretName',
      },
    },
    mode: 'mode',

    // the properties below are optional
    validation: {
      trust: {
        file: {
          certificateChain: 'certificateChain',
        },
        sds: {
          secretName: 'secretName',
        },
      },

      // the properties below are optional
      subjectAlternativeNames: {
        match: {
          exact: ['exact'],
        },
      },
    },
  },
};
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

virtual_gateway_listener_property = appmesh.CfnVirtualGateway.VirtualGatewayListenerProperty(
    port_mapping=appmesh.CfnVirtualGateway.VirtualGatewayPortMappingProperty(
        port=123,
        protocol="protocol"
    ),

    # the properties below are optional
    connection_pool=appmesh.CfnVirtualGateway.VirtualGatewayConnectionPoolProperty(
        grpc=appmesh.CfnVirtualGateway.VirtualGatewayGrpcConnectionPoolProperty(
            max_requests=123
        ),
        http=appmesh.CfnVirtualGateway.VirtualGatewayHttpConnectionPoolProperty(
            max_connections=123,

            # the properties below are optional
            max_pending_requests=123
        ),
        http2=appmesh.CfnVirtualGateway.VirtualGatewayHttp2ConnectionPoolProperty(
            max_requests=123
        )
    ),
    health_check=appmesh.CfnVirtualGateway.VirtualGatewayHealthCheckPolicyProperty(
        healthy_threshold=123,
        interval_millis=123,
        protocol="protocol",
        timeout_millis=123,
        unhealthy_threshold=123,

        # the properties below are optional
        path="path",
        port=123
    ),
    tls=appmesh.CfnVirtualGateway.VirtualGatewayListenerTlsProperty(
        certificate=appmesh.CfnVirtualGateway.VirtualGatewayListenerTlsCertificateProperty(
            acm=appmesh.CfnVirtualGateway.VirtualGatewayListenerTlsAcmCertificateProperty(
                certificate_arn="certificateArn"
            ),
            file=appmesh.CfnVirtualGateway.VirtualGatewayListenerTlsFileCertificateProperty(
                certificate_chain="certificateChain",
                private_key="privateKey"
            ),
            sds=appmesh.CfnVirtualGateway.VirtualGatewayListenerTlsSdsCertificateProperty(
                secret_name="secretName"
            )
        ),
        mode="mode",

        # the properties below are optional
        validation=appmesh.CfnVirtualGateway.VirtualGatewayListenerTlsValidationContextProperty(
            trust=appmesh.CfnVirtualGateway.VirtualGatewayListenerTlsValidationContextTrustProperty(
                file=appmesh.CfnVirtualGateway.VirtualGatewayTlsValidationContextFileTrustProperty(
                    certificate_chain="certificateChain"
                ),
                sds=appmesh.CfnVirtualGateway.VirtualGatewayTlsValidationContextSdsTrustProperty(
                    secret_name="secretName"
                )
            ),

            # the properties below are optional
            subject_alternative_names=appmesh.CfnVirtualGateway.SubjectAlternativeNamesProperty(
                match=appmesh.CfnVirtualGateway.SubjectAlternativeNameMatchersProperty(
                    exact=["exact"]
                )
            )
        )
    )
)
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.*;

VirtualGatewayListenerProperty virtualGatewayListenerProperty = VirtualGatewayListenerProperty.builder()
        .portMapping(VirtualGatewayPortMappingProperty.builder()
                .port(123)
                .protocol("protocol")
                .build())

        // the properties below are optional
        .connectionPool(VirtualGatewayConnectionPoolProperty.builder()
                .grpc(VirtualGatewayGrpcConnectionPoolProperty.builder()
                        .maxRequests(123)
                        .build())
                .http(VirtualGatewayHttpConnectionPoolProperty.builder()
                        .maxConnections(123)

                        // the properties below are optional
                        .maxPendingRequests(123)
                        .build())
                .http2(VirtualGatewayHttp2ConnectionPoolProperty.builder()
                        .maxRequests(123)
                        .build())
                .build())
        .healthCheck(VirtualGatewayHealthCheckPolicyProperty.builder()
                .healthyThreshold(123)
                .intervalMillis(123)
                .protocol("protocol")
                .timeoutMillis(123)
                .unhealthyThreshold(123)

                // the properties below are optional
                .path("path")
                .port(123)
                .build())
        .tls(VirtualGatewayListenerTlsProperty.builder()
                .certificate(VirtualGatewayListenerTlsCertificateProperty.builder()
                        .acm(VirtualGatewayListenerTlsAcmCertificateProperty.builder()
                                .certificateArn("certificateArn")
                                .build())
                        .file(VirtualGatewayListenerTlsFileCertificateProperty.builder()
                                .certificateChain("certificateChain")
                                .privateKey("privateKey")
                                .build())
                        .sds(VirtualGatewayListenerTlsSdsCertificateProperty.builder()
                                .secretName("secretName")
                                .build())
                        .build())
                .mode("mode")

                // the properties below are optional
                .validation(VirtualGatewayListenerTlsValidationContextProperty.builder()
                        .trust(VirtualGatewayListenerTlsValidationContextTrustProperty.builder()
                                .file(VirtualGatewayTlsValidationContextFileTrustProperty.builder()
                                        .certificateChain("certificateChain")
                                        .build())
                                .sds(VirtualGatewayTlsValidationContextSdsTrustProperty.builder()
                                        .secretName("secretName")
                                        .build())
                                .build())

                        // the properties below are optional
                        .subjectAlternativeNames(SubjectAlternativeNamesProperty.builder()
                                .match(SubjectAlternativeNameMatchersProperty.builder()
                                        .exact(List.of("exact"))
                                        .build())
                                .build())
                        .build())
                .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 virtualGatewayListenerProperty = new VirtualGatewayListenerProperty {
    PortMapping = new VirtualGatewayPortMappingProperty {
        Port = 123,
        Protocol = "protocol"
    },

    // the properties below are optional
    ConnectionPool = new VirtualGatewayConnectionPoolProperty {
        Grpc = new VirtualGatewayGrpcConnectionPoolProperty {
            MaxRequests = 123
        },
        Http = new VirtualGatewayHttpConnectionPoolProperty {
            MaxConnections = 123,

            // the properties below are optional
            MaxPendingRequests = 123
        },
        Http2 = new VirtualGatewayHttp2ConnectionPoolProperty {
            MaxRequests = 123
        }
    },
    HealthCheck = new VirtualGatewayHealthCheckPolicyProperty {
        HealthyThreshold = 123,
        IntervalMillis = 123,
        Protocol = "protocol",
        TimeoutMillis = 123,
        UnhealthyThreshold = 123,

        // the properties below are optional
        Path = "path",
        Port = 123
    },
    Tls = new VirtualGatewayListenerTlsProperty {
        Certificate = new VirtualGatewayListenerTlsCertificateProperty {
            Acm = new VirtualGatewayListenerTlsAcmCertificateProperty {
                CertificateArn = "certificateArn"
            },
            File = new VirtualGatewayListenerTlsFileCertificateProperty {
                CertificateChain = "certificateChain",
                PrivateKey = "privateKey"
            },
            Sds = new VirtualGatewayListenerTlsSdsCertificateProperty {
                SecretName = "secretName"
            }
        },
        Mode = "mode",

        // the properties below are optional
        Validation = new VirtualGatewayListenerTlsValidationContextProperty {
            Trust = new VirtualGatewayListenerTlsValidationContextTrustProperty {
                File = new VirtualGatewayTlsValidationContextFileTrustProperty {
                    CertificateChain = "certificateChain"
                },
                Sds = new VirtualGatewayTlsValidationContextSdsTrustProperty {
                    SecretName = "secretName"
                }
            },

            // the properties below are optional
            SubjectAlternativeNames = new SubjectAlternativeNamesProperty {
                Match = new SubjectAlternativeNameMatchersProperty {
                    Exact = new [] { "exact" }
                }
            }
        }
    }
};
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"

virtualGatewayListenerProperty := &VirtualGatewayListenerProperty{
	PortMapping: &VirtualGatewayPortMappingProperty{
		Port: jsii.Number(123),
		Protocol: jsii.String("protocol"),
	},

	// the properties below are optional
	ConnectionPool: &VirtualGatewayConnectionPoolProperty{
		Grpc: &VirtualGatewayGrpcConnectionPoolProperty{
			MaxRequests: jsii.Number(123),
		},
		Http: &VirtualGatewayHttpConnectionPoolProperty{
			MaxConnections: jsii.Number(123),

			// the properties below are optional
			MaxPendingRequests: jsii.Number(123),
		},
		Http2: &VirtualGatewayHttp2ConnectionPoolProperty{
			MaxRequests: jsii.Number(123),
		},
	},
	HealthCheck: &VirtualGatewayHealthCheckPolicyProperty{
		HealthyThreshold: jsii.Number(123),
		IntervalMillis: jsii.Number(123),
		Protocol: jsii.String("protocol"),
		TimeoutMillis: jsii.Number(123),
		UnhealthyThreshold: jsii.Number(123),

		// the properties below are optional
		Path: jsii.String("path"),
		Port: jsii.Number(123),
	},
	Tls: &VirtualGatewayListenerTlsProperty{
		Certificate: &VirtualGatewayListenerTlsCertificateProperty{
			Acm: &VirtualGatewayListenerTlsAcmCertificateProperty{
				CertificateArn: jsii.String("certificateArn"),
			},
			File: &VirtualGatewayListenerTlsFileCertificateProperty{
				CertificateChain: jsii.String("certificateChain"),
				PrivateKey: jsii.String("privateKey"),
			},
			Sds: &VirtualGatewayListenerTlsSdsCertificateProperty{
				SecretName: jsii.String("secretName"),
			},
		},
		Mode: jsii.String("mode"),

		// the properties below are optional
		Validation: &VirtualGatewayListenerTlsValidationContextProperty{
			Trust: &VirtualGatewayListenerTlsValidationContextTrustProperty{
				File: &VirtualGatewayTlsValidationContextFileTrustProperty{
					CertificateChain: jsii.String("certificateChain"),
				},
				Sds: &VirtualGatewayTlsValidationContextSdsTrustProperty{
					SecretName: jsii.String("secretName"),
				},
			},

			// the properties below are optional
			SubjectAlternativeNames: &SubjectAlternativeNamesProperty{
				Match: &SubjectAlternativeNameMatchersProperty{
					Exact: []*string{
						jsii.String("exact"),
					},
				},
			},
		},
	},
}

Properties ​

connectionPooloptionalIResolvable | CfnVirtualGateway.VirtualGatewayConnectionPoolPropertyconnection_pooloptionaltyping.Union[IResolvable, VirtualGatewayConnectionPoolProperty]connectionPooloptionalIResolvableConnectionPooloptionalIResolvableConnectionPooloptionalinterface{} #
The connection pool information for the listener.
healthCheckoptionalIResolvable | CfnVirtualGateway.VirtualGatewayHealthCheckPolicyPropertyhealth_checkoptionaltyping.Union[IResolvable, VirtualGatewayHealthCheckPolicyProperty]healthCheckoptionalIResolvableHealthCheckoptionalIResolvableHealthCheckoptionalinterface{} #
The health check information for the listener.
portMappingIResolvable | CfnVirtualGateway.VirtualGatewayPortMappingPropertyport_mappingtyping.Union[IResolvable, VirtualGatewayPortMappingProperty]portMappingIResolvablePortMappingIResolvablePortMappinginterface{} required #
The port mapping information for the listener.
tlsoptionalIResolvable | CfnVirtualGateway.VirtualGatewayListenerTlsPropertytlsoptionaltyping.Union[IResolvable, VirtualGatewayListenerTlsProperty]tlsoptionalIResolvableTlsoptionalIResolvableTlsoptionalinterface{} #
A reference to an object that represents the Transport Layer Security (TLS) properties for the listener.