Class VirtualNodeProps
The properties used when creating a new VirtualNode.
Inheritance
Namespace: Amazon.CDK.AWS.AppMesh
Assembly: Amazon.CDK.AWS.AppMesh.dll
Syntax (csharp)
public class VirtualNodeProps : Object, IVirtualNodeProps, IVirtualNodeBaseProps
Syntax (vb)
Public Class VirtualNodeProps
Inherits Object
Implements IVirtualNodeProps, IVirtualNodeBaseProps
Remarks
ExampleMetadata: infused
Examples
// A Virtual Node with a gRPC listener with a connection pool set
Mesh mesh;
var node = new VirtualNode(this, "node", new VirtualNodeProps {
Mesh = mesh,
// DNS service discovery can optionally specify the DNS response type as either LOAD_BALANCER or ENDPOINTS.
// LOAD_BALANCER means that the DNS resolver returns a loadbalanced set of endpoints,
// whereas ENDPOINTS means that the DNS resolver is returning all the endpoints.
// By default, the response type is assumed to be LOAD_BALANCER
ServiceDiscovery = ServiceDiscovery.Dns("node", DnsResponseType.ENDPOINTS),
Listeners = new [] { VirtualNodeListener.Http(new HttpVirtualNodeListenerOptions {
Port = 80,
ConnectionPool = new HttpConnectionPool {
MaxConnections = 100,
MaxPendingRequests = 10
}
}) }
});
// A Virtual Gateway with a gRPC listener with a connection pool set
var gateway = new VirtualGateway(this, "gateway", new VirtualGatewayProps {
Mesh = mesh,
Listeners = new [] { VirtualGatewayListener.Grpc(new GrpcGatewayListenerOptions {
Port = 8080,
ConnectionPool = new GrpcConnectionPool {
MaxRequests = 10
}
}) },
VirtualGatewayName = "gateway"
});
Synopsis
Constructors
VirtualNodeProps() |
Properties
AccessLog | Access Logging Configuration for the virtual node. |
BackendDefaults | Default Configuration Virtual Node uses to communicate with Virtual Service. |
Backends | Virtual Services that this is node expected to send outbound traffic to. |
Listeners | Initial listener for the virtual node. |
Mesh | The Mesh which the VirtualNode belongs to. |
ServiceDiscovery | Defines how upstream clients will discover this VirtualNode. |
VirtualNodeName | The name of the VirtualNode. |
Constructors
VirtualNodeProps()
public VirtualNodeProps()
Properties
AccessLog
Access Logging Configuration for the virtual node.
public AccessLog AccessLog { get; set; }
Property Value
Remarks
Default: - No access logging
BackendDefaults
Default Configuration Virtual Node uses to communicate with Virtual Service.
public IBackendDefaults BackendDefaults { get; set; }
Property Value
Remarks
Default: - No Config
Backends
Virtual Services that this is node expected to send outbound traffic to.
public Backend[] Backends { get; set; }
Property Value
Backend[]
Remarks
Default: - No backends
Listeners
Initial listener for the virtual node.
public VirtualNodeListener[] Listeners { get; set; }
Property Value
Remarks
Default: - No listeners
Mesh
ServiceDiscovery
Defines how upstream clients will discover this VirtualNode.
public ServiceDiscovery ServiceDiscovery { get; set; }
Property Value
Remarks
Default: - No Service Discovery
VirtualNodeName
The name of the VirtualNode.
public string VirtualNodeName { get; set; }
Property Value
System.String
Remarks
Default: - A name is automatically determined