AWS::GameLift::GameSessionQueue - AWS CloudFormation

AWS::GameLift::GameSessionQueue

The AWS::GameLift::GameSessionQueue resource creates a placement queue that processes requests for new game sessions. A queue uses FleetIQ algorithms to determine the best placement locations and find an available game server, then prompts the game server to start a new game session. Queues can have destinations (GameLift fleets or aliases), which determine where the queue can place new game sessions. A queue can have destinations with varied fleet type (Spot and On-Demand), instance type, and AWS Region.

Syntax

To declare this entity in your AWS CloudFormation template, use the following syntax:

JSON

{ "Type" : "AWS::GameLift::GameSessionQueue", "Properties" : { "CustomEventData" : String, "Destinations" : [ Destination, ... ], "FilterConfiguration" : FilterConfiguration, "Name" : String, "NotificationTarget" : String, "PlayerLatencyPolicies" : [ PlayerLatencyPolicy, ... ], "PriorityConfiguration" : PriorityConfiguration, "TimeoutInSeconds" : Integer } }

Properties

CustomEventData

Information to be added to all events that are related to this game session queue.

Required: No

Type: String

Minimum: 0

Maximum: 256

Pattern: [\s\S]*

Update requires: No interruption

Destinations

A list of fleets and/or fleet aliases that can be used to fulfill game session placement requests in the queue. Destinations are identified by either a fleet ARN or a fleet alias ARN, and are listed in order of placement preference.

Required: No

Type: List of Destination

Update requires: No interruption

FilterConfiguration

A list of locations where a queue is allowed to place new game sessions. Locations are specified in the form of AWS Region codes, such as us-west-2. If this parameter is not set, game sessions can be placed in any queue location.

Required: No

Type: FilterConfiguration

Update requires: No interruption

Name

A descriptive label that is associated with game session queue. Queue names must be unique within each Region.

Required: Yes

Type: String

Minimum: 1

Maximum: 128

Pattern: [a-zA-Z0-9-]+

Update requires: Replacement

NotificationTarget

An SNS topic ARN that is set up to receive game session placement notifications. See Setting up notifications for game session placement.

Required: No

Type: String

Minimum: 0

Maximum: 300

Pattern: [a-zA-Z0-9:_-]*(\.fifo)?

Update requires: No interruption

PlayerLatencyPolicies

A set of policies that act as a sliding cap on player latency. FleetIQ works to deliver low latency for most players in a game session. These policies ensure that no individual player can be placed into a game with unreasonably high latency. Use multiple policies to gradually relax latency requirements a step at a time. Multiple policies are applied based on their maximum allowed latency, starting with the lowest value.

Required: No

Type: List of PlayerLatencyPolicy

Update requires: No interruption

PriorityConfiguration

Custom settings to use when prioritizing destinations and locations for game session placements. This configuration replaces the FleetIQ default prioritization process. Priority types that are not explicitly named will be automatically applied at the end of the prioritization process.

Required: No

Type: PriorityConfiguration

Update requires: No interruption

TimeoutInSeconds

The maximum time, in seconds, that a new game session placement request remains in the queue. When a request exceeds this time, the game session placement changes to a TIMED_OUT status.

Required: No

Type: Integer

Minimum: 0

Update requires: No interruption

Return values

Ref

When you pass the logical ID of this resource to the intrinsic Ref function, Ref returns the name of the game session queue, which is unique within each Region.

For more information about using the Ref function, see Ref.

Fn::GetAtt

The Fn::GetAtt intrinsic function returns a value for a specified attribute of this type. The following are the available attributes and sample return values.

For more information about using the Fn::GetAtt intrinsic function, see Fn::GetAtt.

Arn

The unique Amazon Resource Name (ARN) for the GameSessionQueue.

Name

A descriptive label that is associated with a game session queue. Names are unique within each Region.

Examples

Create a Game Session Queue

The following example creates a GameLift game session queue named MyGameSessionQueue. The queue is configured with two destinations, one using a fleet ID and one using an alias ID. The queue has a latency policy.

JSON

{ "Resources": { "Queue": { "Type": "AWS::GameLift::GameSessionQueue", "Properties": { "Name": "MyGameSessionQueue", "TimeoutInSeconds": 60, "NotificationTarget": "arn:aws:sns:us-west-2:111122223333:My_Placement_SNS_Topic", "Destinations": [ { "DestinationArn": "arn:aws:gamelift:us-west-2:012345678912:fleet/fleet-id" }, { "DestinationArn": "arn:aws:gamelift:us-west-2:012345678912:alias/alias-id" } ], "PlayerLatencyPolicies": [ { "MaximumIndividualPlayerLatencyMilliseconds": 1000, "PolicyDurationSeconds": 60 } ] } } } }

YAML

Resources: Queue: Type: "AWS::GameLift::GameSessionQueue" Properties: Name: "MyGameSessionQueue" TimeoutInSeconds: 60 NotificationTarget: "arn:aws:sns:us-west-2:111122223333:My_Placement_SNS_Topic" Destinations: # DestinationArn can be either an Alias arn or Fleet arn that you own - DestinationArn: "arn:aws:gamelift:us-west-2:012345678912:fleet/fleet-id" - DestinationArn: "arn:aws:gamelift:us-west-2:012345678912:alias/alias-id" PlayerLatencyPolicies: - MaximumIndividualPlayerLatencyMilliseconds: 1000 PolicyDurationSeconds: 60

See also