Skip to content
v2.277.0

PlayerLatencyPolicyProperty Struct ​

The queue setting that determines the highest latency allowed for individual players when placing a game session.

When a latency policy is in force, a game session cannot be placed with any fleet in a Region where a player reports latency higher than the cap. Latency policies are only enforced when the placement request contains player latency information.

Example ​

ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_gamelift as gamelift } from 'aws-cdk-lib';
const playerLatencyPolicyProperty: gamelift.CfnGameSessionQueue.PlayerLatencyPolicyProperty = {
  maximumIndividualPlayerLatencyMilliseconds: 123,
  policyDurationSeconds: 123,
};
python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_gamelift as gamelift

player_latency_policy_property = gamelift.CfnGameSessionQueue.PlayerLatencyPolicyProperty(
    maximum_individual_player_latency_milliseconds=123,
    policy_duration_seconds=123
)
java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.gamelift.*;

PlayerLatencyPolicyProperty playerLatencyPolicyProperty = PlayerLatencyPolicyProperty.builder()
        .maximumIndividualPlayerLatencyMilliseconds(123)
        .policyDurationSeconds(123)
        .build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.GameLift;

var playerLatencyPolicyProperty = new PlayerLatencyPolicyProperty {
    MaximumIndividualPlayerLatencyMilliseconds = 123,
    PolicyDurationSeconds = 123
};
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"

playerLatencyPolicyProperty := &PlayerLatencyPolicyProperty{
	MaximumIndividualPlayerLatencyMilliseconds: jsii.Number(123),
	PolicyDurationSeconds: jsii.Number(123),
}

Properties ​

maximumIndividualPlayerLatencyMillisecondsoptionalnumbermaximum_individual_player_latency_millisecondsoptionalint | floatmaximumIndividualPlayerLatencyMillisecondsoptionalNumberMaximumIndividualPlayerLatencyMillisecondsoptionaldoubleMaximumIndividualPlayerLatencyMillisecondsoptional*float64#
The maximum latency value that is allowed for any player, in milliseconds.

All policies must have a value set for this property.

policyDurationSecondsoptionalnumberpolicy_duration_secondsoptionalint | floatpolicyDurationSecondsoptionalNumberPolicyDurationSecondsoptionaldoublePolicyDurationSecondsoptional*float64#
The length of time, in seconds, that the policy is enforced while placing a new game session.

A null value for this property means that the policy is enforced until the queue times out.