Class CfnListener.ForwardProperty.Builder
java.lang.Object
software.amazon.awscdk.services.vpclattice.CfnListener.ForwardProperty.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<CfnListener.ForwardProperty>
- Enclosing interface:
CfnListener.ForwardProperty
@Stability(Stable)
public static final class CfnListener.ForwardProperty.Builder
extends Object
implements software.amazon.jsii.Builder<CfnListener.ForwardProperty>
A builder for
CfnListener.ForwardProperty-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds the configured instance.targetGroups(List<? extends Object> targetGroups) Sets the value ofCfnListener.ForwardProperty.getTargetGroups()targetGroups(IResolvable targetGroups) Sets the value ofCfnListener.ForwardProperty.getTargetGroups()
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
targetGroups
@Stability(Stable) public CfnListener.ForwardProperty.Builder targetGroups(IResolvable targetGroups) Sets the value ofCfnListener.ForwardProperty.getTargetGroups()- Parameters:
targetGroups- The target groups. This parameter is required. Traffic matching the rule is forwarded to the specified target groups. With forward actions, you can assign a weight that controls the prioritization and selection of each target group. This means that requests are distributed to individual target groups based on their weights. For example, if two target groups have the same weight, each target group receives half of the traffic.The default value is 1. This means that if only one target group is provided, there is no need to set the weight; 100% of the traffic goes to that target group.
- Returns:
this
-
targetGroups
@Stability(Stable) public CfnListener.ForwardProperty.Builder targetGroups(List<? extends Object> targetGroups) Sets the value ofCfnListener.ForwardProperty.getTargetGroups()- Parameters:
targetGroups- The target groups. This parameter is required. Traffic matching the rule is forwarded to the specified target groups. With forward actions, you can assign a weight that controls the prioritization and selection of each target group. This means that requests are distributed to individual target groups based on their weights. For example, if two target groups have the same weight, each target group receives half of the traffic.The default value is 1. This means that if only one target group is provided, there is no need to set the weight; 100% of the traffic goes to that target group.
- Returns:
this
-
build
Builds the configured instance.- Specified by:
buildin interfacesoftware.amazon.jsii.Builder<CfnListener.ForwardProperty>- Returns:
- a new instance of
CfnListener.ForwardProperty - Throws:
NullPointerException- if any required attribute was not provided
-