@Generated(value="jsii-pacmak/1.58.0 (build f8ba112)", date="2022-05-11T19:24:30.484Z") @Stability(value=Experimental) public interface NetworkTargetGroupProps extends software.amazon.jsii.JsiiSerializable, BaseTargetGroupProps
Example:
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.core.*;
import software.amazon.awscdk.services.ec2.*;
import software.amazon.awscdk.services.elasticloadbalancingv2.*;
Duration duration;
INetworkLoadBalancerTarget networkLoadBalancerTarget;
Vpc vpc;
NetworkTargetGroupProps networkTargetGroupProps = NetworkTargetGroupProps.builder()
.port(123)
// the properties below are optional
.deregistrationDelay(duration)
.healthCheck(HealthCheck.builder()
.enabled(false)
.healthyGrpcCodes("healthyGrpcCodes")
.healthyHttpCodes("healthyHttpCodes")
.healthyThresholdCount(123)
.interval(duration)
.path("path")
.port("port")
.protocol(Protocol.HTTP)
.timeout(duration)
.unhealthyThresholdCount(123)
.build())
.preserveClientIp(false)
.protocol(Protocol.HTTP)
.proxyProtocolV2(false)
.targetGroupName("targetGroupName")
.targets(List.of(networkLoadBalancerTarget))
.targetType(TargetType.INSTANCE)
.vpc(vpc)
.build();
| Modifier and Type | Interface and Description |
|---|---|
static class |
NetworkTargetGroupProps.Builder
A builder for
NetworkTargetGroupProps |
static class |
NetworkTargetGroupProps.Jsii$Proxy
An implementation for
NetworkTargetGroupProps |
| Modifier and Type | Method and Description |
|---|---|
static NetworkTargetGroupProps.Builder |
builder() |
Number |
getPort()
(experimental) The port on which the listener listens for requests.
|
default Boolean |
getPreserveClientIp()
(experimental) Indicates whether client IP preservation is enabled.
|
default Protocol |
getProtocol()
(experimental) Protocol for target group, expects TCP, TLS, UDP, or TCP_UDP.
|
default Boolean |
getProxyProtocolV2()
(experimental) Indicates whether Proxy Protocol version 2 is enabled.
|
default List<INetworkLoadBalancerTarget> |
getTargets()
(experimental) The targets to add to this target group.
|
getDeregistrationDelay, getHealthCheck, getTargetGroupName, getTargetType, getVpc@Stability(value=Experimental) @NotNull Number getPort()
@Stability(value=Experimental) @Nullable default Boolean getPreserveClientIp()
Default: false if the target group type is IP address and the target group protocol is TCP or TLS. Otherwise, true.
@Stability(value=Experimental) @Nullable default Protocol getProtocol()
Default: - TCP
@Stability(value=Experimental) @Nullable default Boolean getProxyProtocolV2()
Default: false
@Stability(value=Experimental) @Nullable default List<INetworkLoadBalancerTarget> getTargets()
Can be Instance, IPAddress, or any self-registering load balancing
target. If you use either Instance or IPAddress as targets, all
target must be of the same type.
Default: - No targets.
@Stability(value=Experimental) static NetworkTargetGroupProps.Builder builder()
builder in interface BaseTargetGroupPropsNetworkTargetGroupProps.Builder of NetworkTargetGroupPropsCopyright © 2022. All rights reserved.