• 沒有找到結果。

Delete a fleet that is no longer in use

在文檔中 GameLift Service (頁 119-126)

This example attempts to delete an existing fleet.

HTTP requests are authenticated using an AWS Signature Version 4 signature in the Authorization header field.

Sample Request

{ "FleetId": "fleet-2222bbbb-33cc-44dd-55ee-6666ffff77aa"

}

See Also

Sample Response

HTTP/1.1 200 OK

x-amzn-RequestId: b34f8665-EXAMPLE Date: Thu, 06 Apr 2017 00:48:07 GMT

See Also

For more information about using this API in one of the language-specific AWS SDKs, see the following:

• AWS Command Line Interface

• AWS SDK for .NET

• AWS SDK for C++

• AWS SDK for Go

• AWS SDK for Java V2

• AWS SDK for JavaScript

• AWS SDK for PHP V3

• AWS SDK for Python

• AWS SDK for Ruby V3

DeleteFleetLocations

DeleteFleetLocations

Removes locations from a multi-location fleet. When deleting a location, all game server process and all instances that are still active in the location are shut down.

To delete fleet locations, identify the fleet ID and provide a list of the locations to be deleted.

If successful, GameLift sets the location status to DELETING, and begins to shut down existing server processes and terminate instances in each location being deleted. When completed, the location status changes to TERMINATED.

Learn more

Setting up GameLift fleets Related actions

CreateFleetLocations (p. 36) | DescribeFleetLocationAttributes (p. 156) |

DescribeFleetLocationCapacity (p. 161) | DescribeFleetLocationUtilization (p. 165) |

DescribeFleetAttributes (p. 140) | DescribeFleetCapacity (p. 146) | DescribeFleetUtilization (p. 174) | UpdateFleetCapacity (p. 354) | StopFleetActions (p. 325) | DeleteFleetLocations (p. 103) | All APIs by task

Request Syntax

{ "FleetId": "string", "Locations": [ "string" ] }

Request Parameters

For information about the parameters that are common to all actions, see Common Parameters (p. 509).

The request accepts the following data in JSON format.

NoteIn the following list, the required parameters are described first.

FleetId (p. 103)

A unique identifier for the fleet to delete locations for. You can use either the fleet ID or ARN value.

Type: String

Pattern: ^fleet-\S+|^arn:.*:fleet\/fleet-\S+

Required: Yes Locations (p. 103)

The list of fleet locations to delete. Specify locations in the form of an AWS Region code, such as us-west-2.

Type: Array of strings

Array Members: Minimum number of 1 item. Maximum number of 100 items.

Response Syntax

Length Constraints: Minimum length of 1. Maximum length of 64.

Pattern: ^[a-z]+(-([a-z]+|\d))*

Required: Yes

Response Syntax

{ "FleetArn": "string", "FleetId": "string", "LocationStates": [ {

"Location": "string", "Status": "string"

} ]}

Response Elements

If the action is successful, the service sends back an HTTP 200 response.

The following data is returned in JSON format by the service.

FleetArn (p. 104)

The Amazon Resource Name (ARN) that is assigned to a GameLift fleet resource and uniquely identifies it. ARNs are unique across all Regions. Format is

arn:aws:gamelift:<region>::fleet/fleet-a1234567-b8c9-0d1e-2fa3-b45c6d7e8912.

Type: String

Pattern: ^arn:.*:fleet\/fleet-\S+

FleetId (p. 104)

A unique identifier for the fleet that location attributes are being deleted for.

Type: String

Pattern: ^fleet-\S+|^arn:.*:fleet\/fleet-\S+

LocationStates (p. 104)

The remote locations that are being deleted, with each location status set to DELETING.

Type: Array of LocationState (p. 466) objects

Errors

For information about the errors that are common to all actions, see Common Errors (p. 511).

InternalServiceException

The service encountered an unrecoverable internal failure while processing the request. Clients can retry such requests immediately or after a waiting period.

See Also

HTTP Status Code: 500 InvalidRequestException

One or more parameter values in the request are invalid. Correct the invalid parameter values before retrying.

HTTP Status Code: 400 NotFoundException

A service resource associated with the request could not be found. Clients should not retry such requests.

HTTP Status Code: 400 UnauthorizedException

The client failed authentication. Clients should not retry such requests.

HTTP Status Code: 400 UnsupportedRegionException

The requested operation is not supported in the Region specified.

HTTP Status Code: 400

See Also

For more information about using this API in one of the language-specific AWS SDKs, see the following:

• AWS Command Line Interface

• AWS SDK for .NET

• AWS SDK for C++

• AWS SDK for Go

• AWS SDK for Java V2

• AWS SDK for JavaScript

• AWS SDK for PHP V3

• AWS SDK for Python

• AWS SDK for Ruby V3

DeleteGameServerGroup

DeleteGameServerGroup

This operation is used with the GameLift FleetIQ solution and game server groups.

Terminates a game server group and permanently deletes the game server group record. You have several options for how these resources are impacted when deleting the game server group. Depending on the type of delete operation selected, this operation might affect these resources:

• The game server group

• The corresponding Auto Scaling group

• All game servers that are currently running in the group

To delete a game server group, identify the game server group to delete and specify the type of delete operation to initiate. Game server groups can only be deleted if they are in ACTIVE or ERROR status.

If the delete request is successful, a series of operations are kicked off. The game server group status is changed to DELETE_SCHEDULED, which prevents new game servers from being registered and stops automatic scaling activity. Once all game servers in the game server group are deregistered, GameLift FleetIQ can begin deleting resources. If any of the delete operations fail, the game server group is placed in ERROR status.

GameLift FleetIQ emits delete events to Amazon CloudWatch.

Learn more

GameLift FleetIQ Guide Related actions

CreateGameServerGroup (p. 40) | ListGameServerGroups (p. 262) | DescribeGameServerGroup (p. 183) | UpdateGameServerGroup (p. 367)

| DeleteGameServerGroup (p. 106) | ResumeGameServerGroup (p. 293) |

SuspendGameServerGroup (p. 334) | DescribeGameServerInstances (p. 187) | All APIs by task

Request Syntax

{ "DeleteOption": "string", "GameServerGroupName": "string"

}

Request Parameters

For information about the parameters that are common to all actions, see Common Parameters (p. 509).

The request accepts the following data in JSON format.

NoteIn the following list, the required parameters are described first.

GameServerGroupName (p. 106)

A unique identifier for the game server group. Use either the GameServerGroup (p. 430) name or ARN value.

Response Syntax

Type: String

Length Constraints: Minimum length of 1. Maximum length of 256.

Pattern: [a-zA-Z0-9-\.]+|^arn:.*:gameservergroup\/[a-zA-Z0-9-\.]+

Required: Yes DeleteOption (p. 106)

The type of delete to perform. Options include the following:

• SAFE_DELETE – (default) Terminates the game server group and Amazon EC2 Auto Scaling group only when it has no game servers that are in UTILIZED status.

• FORCE_DELETE – Terminates the game server group, including all active game servers regardless of their utilization status, and the Amazon EC2 Auto Scaling group.

• RETAIN – Does a safe delete of the game server group but retains the Amazon EC2 Auto Scaling group as is.

Type: String

Valid Values: SAFE_DELETE | FORCE_DELETE | RETAIN Required: No

Response Syntax

{ "GameServerGroup": {

"AutoScalingGroupArn": "string", "BalancingStrategy": "string", "CreationTime": number,

"GameServerGroupArn": "string", "GameServerGroupName": "string", "GameServerProtectionPolicy": "string", "InstanceDefinitions": [

{

"InstanceType": "string", "WeightedCapacity": "string"

} ],

"LastUpdatedTime": number, "RoleArn": "string", "Status": "string", "StatusReason": "string", "SuspendedActions": [ "string" ] }

}

Response Elements

If the action is successful, the service sends back an HTTP 200 response.

The following data is returned in JSON format by the service.

GameServerGroup (p. 107)

An object that describes the deleted game server group resource, with status updated to DELETE_SCHEDULED.

Errors

Type: GameServerGroup (p. 430) object

Errors

For information about the errors that are common to all actions, see Common Errors (p. 511).

InternalServiceException

The service encountered an unrecoverable internal failure while processing the request. Clients can retry such requests immediately or after a waiting period.

HTTP Status Code: 500 InvalidRequestException

One or more parameter values in the request are invalid. Correct the invalid parameter values before retrying.

HTTP Status Code: 400 NotFoundException

A service resource associated with the request could not be found. Clients should not retry such requests.

HTTP Status Code: 400 UnauthorizedException

The client failed authentication. Clients should not retry such requests.

HTTP Status Code: 400

Examples

在文檔中 GameLift Service (頁 119-126)