amazonka-gamelift-1.4.0: Amazon GameLift SDK.

Copyright(c) 2013-2016 Brendan Hay
LicenseMozilla Public License, v. 2.0.
MaintainerBrendan Hay <brendan.g.hay@gmail.com>
Stabilityauto-generated
Portabilitynon-portable (GHC extensions)
Safe HaskellNone
LanguageHaskell2010

Network.AWS.GameLift

Contents

Description

Amazon GameLift Service

Welcome to the Amazon GameLift API Reference. Amazon GameLift is a managed Amazon Web Services (AWS) service for developers who need a scalable, server-based solution for multiplayer games. Amazon GameLift provides setup and deployment of game servers, and handles infrastructure scaling and session management. For more information about the GameLift service, including a feature overview, getting started guide, and tutorial, see the accompanying Amazon GameLift Developer Guide.

This reference describes the low-level service API for GameLift. You can call this API directly or use the AWS SDK for your preferred language. The AWS SDK includes a set of high-level GameLift actions multiplayer game sessions. Alternatively, you can use the AWS command-line interface (CLI) tool, which includes commands for GameLift. For administrative actions, you can use the Amazon GameLift console.

Managing Game and Player Sessions Through GameLift

Call these actions from your game clients and/or services to create and manage multiplayer game sessions.

Setting Up Game Servers

Use these administrative actions to configure GameLift to host your game servers. When configuring GameLift, you'll need to (1) configure a build for your game and provide build files, and (2) set up one or more fleets to host game sessions.

Synopsis

Service Configuration

gameLift :: Service Source

API version '2015-10-01' of the Amazon GameLift SDK configuration.

Errors

Error matchers are designed for use with the functions provided by Control.Exception.Lens. This allows catching (and rethrowing) service specific errors returned by GameLift.

InvalidFleetStatusException

_InvalidFleetStatusException :: AsError a => Getting (First ServiceError) a ServiceError Source

The requested operation would cause a conflict with the current state of a resource associated with the request and/or the fleet. Please resolve the conflict before retrying.

InvalidRequestException

_InvalidRequestException :: AsError a => Getting (First ServiceError) a ServiceError Source

One or more parameters specified as part of the request are invalid. Please correct the invalid parameters before retrying.

ConflictException

_ConflictException :: AsError a => Getting (First ServiceError) a ServiceError Source

The requested operation would cause a conflict with the current state of a service resource associated with the request. Please resolve the conflict before retrying this request.

TerminalRoutingStrategyException

_TerminalRoutingStrategyException :: AsError a => Getting (First ServiceError) a ServiceError Source

The service is unable to resolve the routing for a particular alias because it has a terminal RoutingStrategy associated with it. The message returned in this exception is the message defined in the TerminalRoutingStrategy itself. Such requests should only be retried if the routing strategy for the specified alias is modified.

NotFoundException

_NotFoundException :: AsError a => Getting (First ServiceError) a ServiceError Source

A service resource associated with the request could not be found. Such requests should not be retried by clients.

GameSessionFullException

_GameSessionFullException :: AsError a => Getting (First ServiceError) a ServiceError Source

The game instance is currently full and cannot allow the requested player(s) to join. This exception occurs in response to a CreatePlayerSession request.

InvalidGameSessionStatusException

_InvalidGameSessionStatusException :: AsError a => Getting (First ServiceError) a ServiceError Source

The requested operation would cause a conflict with the current state of a resource associated with the request and/or the game instance. Such requests should not be retried by clients without resolving the conflict.

InternalServiceException

_InternalServiceException :: AsError a => Getting (First ServiceError) a ServiceError Source

The service encountered an unrecoverable internal failure while processing the request. Such requests can be retried by clients, either immediately or after a back-off period.

UnauthorizedException

_UnauthorizedException :: AsError a => Getting (First ServiceError) a ServiceError Source

The client failed authentication. Such requests should not be retried without valid authentication credentials.

FleetCapacityExceededException

_FleetCapacityExceededException :: AsError a => Getting (First ServiceError) a ServiceError Source

The specified fleet has no available instances to fulfill a request to create a new game session. Such requests should only be retried once the fleet capacity has been increased.

LimitExceededException

_LimitExceededException :: AsError a => Getting (First ServiceError) a ServiceError Source

The requested operation would cause the resource to exceed the allowed service limit. Please resolve the issue before retrying.

Waiters

Waiters poll by repeatedly sending a request until some remote success condition configured by the Wait specification is fulfilled. The Wait specification determines how many attempts should be made, in addition to delay and retry strategies.

Operations

Some AWS operations return results that are incomplete and require subsequent requests in order to obtain the entire result set. The process of sending subsequent requests to continue where a previous request left off is called pagination. For example, the ListObjects operation of Amazon S3 returns up to 1000 objects at a time, and you must send subsequent requests with the appropriate Marker in order to retrieve the next page of results.

Operations that have an AWSPager instance can transparently perform subsequent requests, correctly setting Markers and other request facets to iterate through the entire result set of a truncated API operation. Operations which support this have an additional note in the documentation.

Many operations have the ability to filter results on the server side. See the individual operation parameters for details.

CreateGameSession

DeleteScalingPolicy

PutScalingPolicy

ListBuilds

DeleteFleet

CreateBuild

RequestUploadCredentials

CreateAlias

ResolveAlias

ListAliases

DescribeScalingPolicies

DescribeGameSessions

DescribeFleetUtilization

GetGameSessionLogURL

DescribeFleetAttributes

DescribeFleetEvents

DescribeFleetCapacity

DeleteBuild

UpdateBuild

ListFleets

DeleteAlias

UpdateAlias

DescribeGameSessionDetails

DescribeFleetPortSettings

CreatePlayerSessions

CreateFleet

UpdateFleetAttributes

DescribePlayerSessions

DescribeBuild

UpdateFleetPortSettings

UpdateFleetCapacity

DescribeAlias

DescribeEC2InstanceLimits

UpdateGameSession

CreatePlayerSession

Types

BuildStatus

ComparisonOperatorType

EC2InstanceType

EventCode

FleetStatus

GameSessionStatus

IPProtocol

MetricName

PlayerSessionCreationPolicy

PlayerSessionStatus

ProtectionPolicy

RoutingStrategyType

ScalingAdjustmentType

ScalingStatusType

AWSCredentials

data AWSCredentials Source

AWS access credentials required to upload game build files to Amazon GameLift. These credentials are generated with CreateBuild, and are valid for a limited time. If they expire before you upload your game build, get a new set by calling RequestUploadCredentials.

See: awsCredentials smart constructor.

awsCredentials :: AWSCredentials Source

Creates a value of AWSCredentials with the minimum fields required to make a request.

Use one of the following lenses to modify other fields as desired:

acSecretAccessKey :: Lens' AWSCredentials (Maybe Text) Source

Secret key for an AWS account.

acSessionToken :: Lens' AWSCredentials (Maybe Text) Source

Token specific to a build ID.

acAccessKeyId :: Lens' AWSCredentials (Maybe Text) Source

Access key for an AWS account.

Alias

data Alias Source

Properties describing a fleet alias.

See: alias smart constructor.

alias :: Alias Source

Creates a value of Alias with the minimum fields required to make a request.

Use one of the following lenses to modify other fields as desired:

aCreationTime :: Lens' Alias (Maybe UTCTime) Source

Time stamp indicating when this object was created. Format is an integer representing the number of seconds since the Unix epoch (Unix time).

aLastUpdatedTime :: Lens' Alias (Maybe UTCTime) Source

Time stamp indicating when this object was last modified. Format is an integer representing the number of seconds since the Unix epoch (Unix time).

aAliasId :: Lens' Alias (Maybe Text) Source

Unique identifier for a fleet alias.

aName :: Lens' Alias (Maybe Text) Source

Descriptive label associated with this alias. Alias names do not need to be unique.

aDescription :: Lens' Alias (Maybe Text) Source

Human-readable description of the alias.

Build

data Build Source

Properties describing a game build.

See: build smart constructor.

build :: Build Source

Creates a value of Build with the minimum fields required to make a request.

Use one of the following lenses to modify other fields as desired:

bCreationTime :: Lens' Build (Maybe UTCTime) Source

Time stamp indicating when this object was created. Format is an integer representing the number of seconds since the Unix epoch (Unix time).

bStatus :: Lens' Build (Maybe BuildStatus) Source

Current status of the build. Possible build states include:

  • INITIALIZED: A new build has been defined, but no files have been uploaded. You cannot create fleets for builds that are in this state. When a build is successfully created, the build state is set to this value.
  • READY: The game build has been successfully uploaded. You can now create new fleets for this build.
  • FAILED: The game build upload failed. You cannot create new fleets for this build.

bBuildId :: Lens' Build (Maybe Text) Source

Unique identifier for a build.

bName :: Lens' Build (Maybe Text) Source

Descriptive label associated with this build. Build names do not need to be unique. It can be set using CreateBuild or UpdateBuild.

bVersion :: Lens' Build (Maybe Text) Source

Version associated with this build. Version strings do not need to be unique to a build. This value can be set using CreateBuild or UpdateBuild.

bSizeOnDisk :: Lens' Build (Maybe Natural) Source

File size of the uploaded game build, expressed in bytes. When the build state is INITIALIZED, this value is 0.

EC2InstanceCounts

data EC2InstanceCounts Source

Current status of fleet capacity. The number of active instances should match or be in the process of matching the number of desired instances. Pending and terminating counts are non-zero only if fleet capacity is adjusting to an UpdateFleetCapacity request, or if access to resources is temporarily affected.

See: ec2InstanceCounts smart constructor.

ec2InstanceCounts :: EC2InstanceCounts Source

Creates a value of EC2InstanceCounts with the minimum fields required to make a request.

Use one of the following lenses to modify other fields as desired:

eicIdLE :: Lens' EC2InstanceCounts (Maybe Natural) Source

Number of active instances in the fleet that are not currently hosting a game session.

eicTERMINATING :: Lens' EC2InstanceCounts (Maybe Natural) Source

Number of instances in the fleet that are no longer active but haven't yet been terminated.

eicPENDING :: Lens' EC2InstanceCounts (Maybe Natural) Source

Number of instances in the fleet that are starting but not yet active.

eicMAXIMUM :: Lens' EC2InstanceCounts (Maybe Natural) Source

Maximum value allowed for the fleet's instance count.

eicDESIRED :: Lens' EC2InstanceCounts (Maybe Natural) Source

Ideal number of active instances in the fleet.

eicMINIMUM :: Lens' EC2InstanceCounts (Maybe Natural) Source

Minimum value allowed for the fleet's instance count.

eicACTIVE :: Lens' EC2InstanceCounts (Maybe Natural) Source

Actual number of active instances in the fleet.

EC2InstanceLimit

data EC2InstanceLimit Source

Maximum number of instances allowed based on the Amazon Elastic Compute Cloud (Amazon EC2) instance type. Instance limits can be retrieved by calling DescribeEC2InstanceLimits.

See: ec2InstanceLimit smart constructor.

ec2InstanceLimit :: EC2InstanceLimit Source

Creates a value of EC2InstanceLimit with the minimum fields required to make a request.

Use one of the following lenses to modify other fields as desired:

eilEC2InstanceType :: Lens' EC2InstanceLimit (Maybe EC2InstanceType) Source

Type of EC2 instances used in the fleet. EC2 instance types define the CPU, memory, storage, and networking capacity of the fleetaposs hosts. Amazon GameLift supports the EC2 instance types listed below. See Amazon EC2 Instance Types for detailed descriptions of each.

eilCurrentInstances :: Lens' EC2InstanceLimit (Maybe Natural) Source

Number of instances of the specified type that are currently in use by this AWS account.

eilInstanceLimit :: Lens' EC2InstanceLimit (Maybe Natural) Source

Number of instances allowed.

Event

data Event Source

Log entry describing an event involving an Amazon GameLift resource (such as a fleet).

See: event smart constructor.

event :: Event Source

Creates a value of Event with the minimum fields required to make a request.

Use one of the following lenses to modify other fields as desired:

eResourceId :: Lens' Event (Maybe Text) Source

Unique identifier for the resource, such as a fleet ID.

eEventTime :: Lens' Event (Maybe UTCTime) Source

Time stamp indicating when this event occurred. Format is an integer representing the number of seconds since the Unix epoch (Unix time).

eMessage :: Lens' Event (Maybe Text) Source

Additional information related to the event.

eEventCode :: Lens' Event (Maybe EventCode) Source

Type of event being logged.

eEventId :: Lens' Event (Maybe Text) Source

Unique identifier for a fleet event.

FleetAttributes

fleetAttributes :: FleetAttributes Source

Creates a value of FleetAttributes with the minimum fields required to make a request.

Use one of the following lenses to modify other fields as desired:

faCreationTime :: Lens' FleetAttributes (Maybe UTCTime) Source

Time stamp indicating when this object was created. Format is an integer representing the number of seconds since the Unix epoch (Unix time).

faStatus :: Lens' FleetAttributes (Maybe FleetStatus) Source

Current status of the fleet. Possible fleet states include:

  • NEW: A new fleet has been defined and hosts allocated.
  • DOWNLOADING/VALIDATING/BUILDING/ACTIVATING: The new fleet is being set up with the game build, and new hosts are being started.
  • ACTIVE: Hosts can now accept game sessions.
  • ERROR: An error occurred when downloading, validating, building, or activating the fleet.
  • DELETING: Hosts are responding to a delete fleet request.
  • TERMINATED: The fleet no longer exists.

faServerLaunchParameters :: Lens' FleetAttributes (Maybe Text) Source

Parameters required to launch your game server. These parameters should be expressed as a string of command-line parameters. Example: "+sv_port 33435 +start_lobby".

faLogPaths :: Lens' FleetAttributes [Text] Source

Path to game-session log files generated by your game server. Once a game session has been terminated, Amazon GameLift captures and stores the logs on Amazon S3. Use the GameLift console to access the stored logs.

faBuildId :: Lens' FleetAttributes (Maybe Text) Source

Unique identifier for a build.

faTerminationTime :: Lens' FleetAttributes (Maybe UTCTime) Source

Time stamp indicating when this fleet was terminated. Format is an integer representing the number of seconds since the Unix epoch (Unix time).

faNewGameSessionProtectionPolicy :: Lens' FleetAttributes (Maybe ProtectionPolicy) Source

Type of game session protection to set for all new instances started in the fleet.

  • NoProtection: The game session can be terminated during a scale-down event.
  • FullProtection: If the game session is in an ACTIVE status, it cannot be terminated during a scale-down event.

faName :: Lens' FleetAttributes (Maybe Text) Source

Descriptive label associated with this fleet. Fleet names do not need to be unique.

faServerLaunchPath :: Lens' FleetAttributes (Maybe Text) Source

Path to the launch executable for the game server. A game server is built into a 'C:\\game' drive. This value must be expressed as 'C:\game\[launchpath]'. Example: If, when built, your game server files are in a folder called "MyGame", your log path should be 'C:\\game\\MyGame\\server.exe'.

faFleetId :: Lens' FleetAttributes (Maybe Text) Source

Unique identifier for a fleet.

faDescription :: Lens' FleetAttributes (Maybe Text) Source

Human-readable description of the fleet.

FleetCapacity

data FleetCapacity Source

Information about the fleet's capacity. Fleet capacity is measured in EC2 instances. By default, new fleets have a capacity of one instance, but can be updated as needed. The maximum number of instances for a fleet is determined by the fleet's instance type.

See: fleetCapacity smart constructor.

fleetCapacity :: FleetCapacity Source

Creates a value of FleetCapacity with the minimum fields required to make a request.

Use one of the following lenses to modify other fields as desired:

fcInstanceType :: Lens' FleetCapacity (Maybe EC2InstanceType) Source

Type of EC2 instances used in the fleet. EC2 instance types define the CPU, memory, storage, and networking capacity of the fleetaposs hosts. Amazon GameLift supports the EC2 instance types listed below. See Amazon EC2 Instance Types for detailed descriptions of each.

fcFleetId :: Lens' FleetCapacity (Maybe Text) Source

Unique identifier for a fleet.

fcInstanceCounts :: Lens' FleetCapacity (Maybe EC2InstanceCounts) Source

Current status of fleet capacity.

FleetUtilization

data FleetUtilization Source

Current status of fleet utilization, including the number of game and player sessions being hosted.

See: fleetUtilization smart constructor.

fleetUtilization :: FleetUtilization Source

Creates a value of FleetUtilization with the minimum fields required to make a request.

Use one of the following lenses to modify other fields as desired:

fuActiveGameSessionCount :: Lens' FleetUtilization (Maybe Natural) Source

Number of active game sessions currently being hosted on fleet game servers.

fuMaximumPlayerSessionCount :: Lens' FleetUtilization (Maybe Natural) Source

Maximum players allowed across all game sessions currently hosted in the fleet.

fuCurrentPlayerSessionCount :: Lens' FleetUtilization (Maybe Natural) Source

Number of active player sessions currently being hosted on fleet game servers.

fuFleetId :: Lens' FleetUtilization (Maybe Text) Source

Unique identifier for a fleet.

GameProperty

data GameProperty Source

Set of key-value pairs containing information your game server requires to set up sessions. This object allows you to pass in any set of data needed for your game. For more information, see the Amazon GameLift Developer Guide.

See: gameProperty smart constructor.

gameProperty Source

Creates a value of GameProperty with the minimum fields required to make a request.

Use one of the following lenses to modify other fields as desired:

gpKey :: Lens' GameProperty Text Source

Undocumented member.

gpValue :: Lens' GameProperty Text Source

Undocumented member.

GameSession

gsCreationTime :: Lens' GameSession (Maybe UTCTime) Source

Time stamp indicating when this object was created. Format is an integer representing the number of seconds since the Unix epoch (Unix time).

gsStatus :: Lens' GameSession (Maybe GameSessionStatus) Source

Current status of the game session. A game session must be in an ACTIVE state to have player sessions.

gsGameProperties :: Lens' GameSession [GameProperty] Source

Set of custom properties for the game session.

gsIPAddress :: Lens' GameSession (Maybe Text) Source

IP address of the game session.

gsGameSessionId :: Lens' GameSession (Maybe Text) Source

Unique identifier for a game session.

gsMaximumPlayerSessionCount :: Lens' GameSession (Maybe Natural) Source

Maximum number of players allowed in the game session.

gsTerminationTime :: Lens' GameSession (Maybe UTCTime) Source

Time stamp indicating when this fleet was terminated. Format is an integer representing the number of seconds since the Unix epoch (Unix time).

gsPlayerSessionCreationPolicy :: Lens' GameSession (Maybe PlayerSessionCreationPolicy) Source

Indicates whether or not the game session is accepting new players.

gsName :: Lens' GameSession (Maybe Text) Source

Descriptive label associated with this game session. Session names do not need to be unique.

gsCurrentPlayerSessionCount :: Lens' GameSession (Maybe Natural) Source

Number of players currently in the game session.

gsFleetId :: Lens' GameSession (Maybe Text) Source

Unique identifier for a fleet.

GameSessionDetail

gameSessionDetail :: GameSessionDetail Source

Creates a value of GameSessionDetail with the minimum fields required to make a request.

Use one of the following lenses to modify other fields as desired:

gsdProtectionPolicy :: Lens' GameSessionDetail (Maybe ProtectionPolicy) Source

Current status of protection for the game session.

  • NoProtection: The game session can be terminated during a scale-down event.
  • FullProtection: If the game session is in an ACTIVE status, it cannot be terminated during a scale-down event.

IPPermission

data IPPermission Source

IP addresses and port settings used to limit access by incoming traffic (players) to a fleet. Permissions specify a range of IP addresses and port settings that must be used to gain access to a game server on a fleet machine.

See: ipPermission smart constructor.

ipPermission Source

Creates a value of IPPermission with the minimum fields required to make a request.

Use one of the following lenses to modify other fields as desired:

ipFromPort :: Lens' IPPermission Natural Source

Starting value for a range of allowed port numbers.

ipToPort :: Lens' IPPermission Natural Source

Ending value for a range of allowed port numbers. Port numbers are end-inclusive. This value must be higher than FromPort.

ipIPRange :: Lens' IPPermission Text Source

Range of allowed IP addresses. This value must be expressed in CIDR notation. Example: "'000.000.000.000/[subnet mask]'" or optionally the shortened version "'0.0.0.0/[subnet mask]'".

ipProtocol :: Lens' IPPermission IPProtocol Source

Network communication protocol used by the fleet.

PlayerSession

playerSession :: PlayerSession Source

Creates a value of PlayerSession with the minimum fields required to make a request.

Use one of the following lenses to modify other fields as desired:

psCreationTime :: Lens' PlayerSession (Maybe UTCTime) Source

Time stamp indicating when this object was created. Format is an integer representing the number of seconds since the Unix epoch (Unix time).

psStatus :: Lens' PlayerSession (Maybe PlayerSessionStatus) Source

Current status of the player session. Possible player session states include:

  • RESERVED: The player session request has been received, but the player has not yet connected to the game server and/or been validated.
  • ACTIVE: The player has been validated by the game server and is currently connected.
  • COMPLETED: The player connection has been dropped.
  • TIMEDOUT: A player session request was received, but the player did not connect and/or was not validated within the time-out limit (60 seconds).

psIPAddress :: Lens' PlayerSession (Maybe Text) Source

Game session IP address. All player sessions reference the game session location.

psGameSessionId :: Lens' PlayerSession (Maybe Text) Source

Unique identifier for a game session.

psTerminationTime :: Lens' PlayerSession (Maybe UTCTime) Source

Time stamp indicating when this fleet was terminated. Format is an integer representing the number of seconds since the Unix epoch (Unix time).

psPlayerSessionId :: Lens' PlayerSession (Maybe Text) Source

Unique identifier for a player session.

psFleetId :: Lens' PlayerSession (Maybe Text) Source

Unique identifier for a fleet.

psPlayerId :: Lens' PlayerSession (Maybe Text) Source

Unique identifier for a player.

RoutingStrategy

routingStrategy :: RoutingStrategy Source

Creates a value of RoutingStrategy with the minimum fields required to make a request.

Use one of the following lenses to modify other fields as desired:

rsType :: Lens' RoutingStrategy (Maybe RoutingStrategyType) Source

Type of routing strategy. Possible routing types include:

  • SIMPLE: The alias resolves to one specific fleet. Use this type when routing to active fleets.
  • TERMINAL: The alias does not resolve to a fleet but instead can be used to display a message to the user. A terminal alias throws a TerminalRoutingStrategyException with the RoutingStrategy message embedded.

rsMessage :: Lens' RoutingStrategy (Maybe Text) Source

Message text to be used with a terminal routing strategy.

rsFleetId :: Lens' RoutingStrategy (Maybe Text) Source

Unique identifier for a fleet.

S3Location

data S3Location Source

Location in Amazon Simple Storage Service (Amazon S3) where a build's files are stored. This location is assigned in response to a CreateBuild call, and is always in the same region as the service used to create the build. For more details see the Amazon S3 documentation.

See: s3Location smart constructor.

s3Location :: S3Location Source

Creates a value of S3Location with the minimum fields required to make a request.

Use one of the following lenses to modify other fields as desired:

slBucket :: Lens' S3Location (Maybe Text) Source

Amazon S3 bucket identifier.

slKey :: Lens' S3Location (Maybe Text) Source

Amazon S3 bucket key.

slRoleARN :: Lens' S3Location (Maybe Text) Source

Undocumented member.

ScalingPolicy

data ScalingPolicy Source

Rule that controls how a fleet is scaled. Scaling policies are uniquely identified by the combination of name and fleet ID.

See: scalingPolicy smart constructor.

scalingPolicy :: ScalingPolicy Source

Creates a value of ScalingPolicy with the minimum fields required to make a request.

Use one of the following lenses to modify other fields as desired:

spStatus :: Lens' ScalingPolicy (Maybe ScalingStatusType) Source

Current status of the scaling policy. The scaling policy is only in force when in an Active state.

  • ACTIVE: The scaling policy is currently in force.
  • UPDATEREQUESTED: A request to update the scaling policy has been received.
  • UPDATING: A change is being made to the scaling policy.
  • DELETEREQUESTED: A request to delete the scaling policy has been received.
  • DELETING: The scaling policy is being deleted.
  • DELETED: The scaling policy has been deleted.
  • ERROR: An error occurred in creating the policy. It should be removed and recreated.

spScalingAdjustmentType :: Lens' ScalingPolicy (Maybe ScalingAdjustmentType) Source

Type of adjustment to make to a fleet's instance count (see FleetCapacity):

  • ChangeInCapacity: add (or subtract) the scaling adjustment value from the current instance count. Positive values scale up while negative values scale down.
  • ExactCapacity: set the instance count to the scaling adjustment value.
  • PercentChangeInCapacity: increase or reduce the current instance count by the scaling adjustment, read as a percentage. Positive values scale up while negative values scale down.

spEvaluationPeriods :: Lens' ScalingPolicy (Maybe Natural) Source

Length of time (in minutes) the metric must be at or beyond the threshold before a scaling event is triggered.

spMetricName :: Lens' ScalingPolicy (Maybe MetricName) Source

Name of the GameLift-defined metric that is used to trigger an adjustment.

  • ActivatingGameSessions: number of game sessions in the process of being created (game session status = ACTIVATING).
  • ActiveGameSessions: number of game sessions currently running (game session status = ACTIVE).
  • CurrentPlayerSessions: number of active or reserved player sessions (player session status = ACTIVE or RESERVED).
  • AvailablePlayerSessions: number of player session slots currently available in active game sessions across the fleet, calculated by subtracting a game session's current player session count from its maximum player session count. This number does include game sessions that are not currently accepting players (game session PlayerSessionCreationPolicy = DENY_ALL).
  • ActiveInstances: number of instances currently running a game session.
  • IdleInstances: number of instances not currently running a game session.

spComparisonOperator :: Lens' ScalingPolicy (Maybe ComparisonOperatorType) Source

Comparison operator to use when measuring a metric against the threshold value.

spName :: Lens' ScalingPolicy (Maybe Text) Source

Descriptive label associated with this scaling policy. Policy names do not need to be unique.

spThreshold :: Lens' ScalingPolicy (Maybe Double) Source

Metric value used to trigger a scaling event.

spScalingAdjustment :: Lens' ScalingPolicy (Maybe Int) Source

Amount of adjustment to make, based on the scaling adjustment type.

spFleetId :: Lens' ScalingPolicy (Maybe Text) Source

Unique identity for the fleet associated with this scaling policy.