/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include Describes a forward action. You can use forward actions to route requests to
* one or more target groups. See Also:
AWS
* API Reference
The target groups. 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 traffic will go to that * target group.
*/ inline const Aws::VectorThe target groups. 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 traffic will go to that * target group.
*/ inline bool TargetGroupsHasBeenSet() const { return m_targetGroupsHasBeenSet; } /** *The target groups. 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 traffic will go to that * target group.
*/ inline void SetTargetGroups(const Aws::VectorThe target groups. 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 traffic will go to that * target group.
*/ inline void SetTargetGroups(Aws::VectorThe target groups. 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 traffic will go to that * target group.
*/ inline ForwardAction& WithTargetGroups(const Aws::VectorThe target groups. 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 traffic will go to that * target group.
*/ inline ForwardAction& WithTargetGroups(Aws::VectorThe target groups. 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 traffic will go to that * target group.
*/ inline ForwardAction& AddTargetGroups(const WeightedTargetGroup& value) { m_targetGroupsHasBeenSet = true; m_targetGroups.push_back(value); return *this; } /** *The target groups. 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 traffic will go to that * target group.
*/ inline ForwardAction& AddTargetGroups(WeightedTargetGroup&& value) { m_targetGroupsHasBeenSet = true; m_targetGroups.push_back(std::move(value)); return *this; } private: Aws::Vector