Interface AutoScalingPolicy
- All Superinterfaces:
software.amazon.jsii.JsiiSerializable
- All Known Implementing Classes:
AutoScalingPolicy.Jsii$Proxy
@Generated(value="jsii-pacmak/1.109.0 (build c221850)",
date="2025-03-14T03:25:07.750Z")
@Stability(Experimental)
public interface AutoScalingPolicy
extends software.amazon.jsii.JsiiSerializable
(experimental) Configuration settings for intelligent automatic scaling that uses target tracking.
After the Auto Scaling group is created, all updates to Auto Scaling policies, including changing this policy and adding or removing other policies, is done directly on the Auto Scaling group.
Example:
ILaunchTemplate launchTemplate; IVpc vpc; GameServerGroup.Builder.create(this, "Game server group") .gameServerGroupName("sample-gameservergroup-name") .instanceDefinitions(List.of(InstanceDefinition.builder() .instanceType(InstanceType.of(InstanceClass.C5, InstanceSize.LARGE)) .build(), InstanceDefinition.builder() .instanceType(InstanceType.of(InstanceClass.C4, InstanceSize.LARGE)) .build())) .launchTemplate(launchTemplate) .vpc(vpc) .autoScalingPolicy(AutoScalingPolicy.builder() .estimatedInstanceWarmup(Duration.minutes(5)) .targetTrackingConfiguration(5) .build()) .build();
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic final class
A builder forAutoScalingPolicy
static final class
An implementation forAutoScalingPolicy
-
Method Summary
Modifier and TypeMethodDescriptionstatic AutoScalingPolicy.Builder
builder()
default Duration
(experimental) Length of time, it takes for a new instance to start new game server processes and register with GameLift FleetIQ.(experimental) Settings for a target-based scaling policy applied to Auto Scaling group.Methods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Method Details
-
getTargetTrackingConfiguration
(experimental) Settings for a target-based scaling policy applied to Auto Scaling group.These settings are used to create a target-based policy that tracks the GameLift FleetIQ metric
PercentUtilizedGameServers
and specifies a target value for the metric.As player usage changes, the policy triggers to adjust the game server group capacity so that the metric returns to the target value.
-
getEstimatedInstanceWarmup
(experimental) Length of time, it takes for a new instance to start new game server processes and register with GameLift FleetIQ.Specifying a warm-up time can be useful, particularly with game servers that take a long time to start up, because it avoids prematurely starting new instances.
Default: no instance warmup duration settled
-
builder
- Returns:
- a
AutoScalingPolicy.Builder
ofAutoScalingPolicy
-