RequestCountScalingProps¶
-
class
aws_cdk.aws_autoscaling.
RequestCountScalingProps
(*, cooldown=None, disable_scale_in=None, estimated_instance_warmup=None, target_requests_per_minute=None, target_requests_per_second=None)¶ Bases:
aws_cdk.aws_autoscaling.BaseTargetTrackingProps
Properties for enabling scaling based on request/second.
- Parameters
cooldown (
Optional
[Duration
]) – Period after a scaling completes before another scaling activity can start. Default: - The default cooldown configured on the AutoScalingGroup.disable_scale_in (
Optional
[bool
]) – Indicates whether scale in by the target tracking policy is disabled. If the value is true, scale in is disabled and the target tracking policy won’t remove capacity from the autoscaling group. Otherwise, scale in is enabled and the target tracking policy can remove capacity from the group. Default: falseestimated_instance_warmup (
Optional
[Duration
]) – Estimated time until a newly launched instance can send metrics to CloudWatch. Default: - Same as the cooldown.target_requests_per_minute (
Union
[int
,float
,None
]) – Target average requests/minute on each instance. Default: - Specify exactly one of ‘targetRequestsPerMinute’ and ‘targetRequestsPerSecond’target_requests_per_second (
Union
[int
,float
,None
]) – (deprecated) Target average requests/seconds on each instance. Default: - Specify exactly one of ‘targetRequestsPerMinute’ and ‘targetRequestsPerSecond’
- ExampleMetadata
infused
Example:
# auto_scaling_group: autoscaling.AutoScalingGroup auto_scaling_group.scale_on_request_count("LimitRPS", target_requests_per_second=1000 )
Attributes
-
cooldown
¶ Period after a scaling completes before another scaling activity can start.
- Default
The default cooldown configured on the AutoScalingGroup.
- Return type
Optional
[Duration
]
-
disable_scale_in
¶ Indicates whether scale in by the target tracking policy is disabled.
If the value is true, scale in is disabled and the target tracking policy won’t remove capacity from the autoscaling group. Otherwise, scale in is enabled and the target tracking policy can remove capacity from the group.
- Default
false
- Return type
Optional
[bool
]
-
estimated_instance_warmup
¶ Estimated time until a newly launched instance can send metrics to CloudWatch.
- Default
Same as the cooldown.
- Return type
Optional
[Duration
]
-
target_requests_per_minute
¶ Target average requests/minute on each instance.
- Default
Specify exactly one of ‘targetRequestsPerMinute’ and ‘targetRequestsPerSecond’
- Return type
Union
[int
,float
,None
]
-
target_requests_per_second
¶ (deprecated) Target average requests/seconds on each instance.
- Default
Specify exactly one of ‘targetRequestsPerMinute’ and ‘targetRequestsPerSecond’
- Deprecated
Use ‘targetRequestsPerMinute’ instead
- Stability
deprecated
- Return type
Union
[int
,float
,None
]