Skip to main content

locations

Creates, updates, deletes, gets or lists a locations resource.

Overview

Namelocations
TypeResource
Idaws.gamelift.locations

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
location_arnstringThe Amazon Resource Name (ARN) that is assigned to a custom location resource and uniquely identifies it. ARNs are unique across all Regions. Format is arn:aws:gamelift:<region>::location/location-a1234567-b8c9-0d1e-2fa3-b45c6d7e8912. (pattern: <code>^arn:.*:location/custom-\S+$</code>)
location_namestringThe location's name. (pattern: <code>^[A-Za-z0-9-]+$</code>)
ping_beaconobjectInformation about the UDP ping beacon for this location. Ping beacons are fixed endpoints that you can use to measure network latency between a player device and an Amazon GameLift Servers hosting location.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
list_locationsselectregionThis API works with the following fleet types: EC2, Anywhere, Container Lists all custom and Amazon Web Services locations where Amazon GameLift Servers can host game servers. This operation also returns UDP ping beacon information for locations, which you can use to measure network latency between player devices and potential hosting locations. Learn more Service locations
create_fleet_locationsinsertregion, FleetId, LocationsThis API works with the following fleet types: EC2, Anywhere, Container Adds remote locations to an EC2 and begins populating the new locations with instances. The new instances conform to the fleet's instance type, auto-scaling, and other configuration settings. You can't add remote locations to a fleet that resides in an Amazon Web Services Region that doesn't support multiple locations. Fleets created prior to March 2021 can't support multiple locations. To add fleet locations, specify the fleet to be updated and provide a list of one or more locations. If successful, this operation returns the list of added locations with their status set to NEW. Amazon GameLift Servers initiates the process of starting an instance in each added location. You can track the status of each new location by monitoring location creation events using DescribeFleetEvents. Learn more Setting up fleets Update fleet locations Amazon GameLift Servers service locations for managed hosting.
create_locationinsertregion, LocationNameThis API works with the following fleet types: Anywhere Creates a custom location for use in an Anywhere fleet.
delete_fleet_locationsdeleteregionThis API works with the following fleet types: EC2, Anywhere, Container 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 Amazon GameLift Servers fleets
delete_locationdeleteregionThis API works with the following fleet types: Anywhere Deletes a custom location. Before deleting a custom location, review any fleets currently using the custom location and deregister the location if it is in use. For more information, see DeregisterCompute.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
regionstringAWS region (default: us-east-1)

SELECT examples

This API works with the following fleet types: EC2, Anywhere, Container Lists all custom and Amazon Web Services locations where Amazon GameLift Servers can host game servers. This operation also returns UDP ping beacon information for locations, which you can use to measure network latency between player devices and potential hosting locations. Learn more Service locations

SELECT
location_arn,
location_name,
ping_beacon
FROM aws.gamelift.locations
WHERE region = '{{ region }}' -- required
;

INSERT examples

This API works with the following fleet types: EC2, Anywhere, Container Adds remote locations to an EC2 and begins populating the new locations with instances. The new instances conform to the fleet's instance type, auto-scaling, and other configuration settings. You can't add remote locations to a fleet that resides in an Amazon Web Services Region that doesn't support multiple locations. Fleets created prior to March 2021 can't support multiple locations. To add fleet locations, specify the fleet to be updated and provide a list of one or more locations. If successful, this operation returns the list of added locations with their status set to NEW. Amazon GameLift Servers initiates the process of starting an instance in each added location. You can track the status of each new location by monitoring location creation events using DescribeFleetEvents. Learn more Setting up fleets Update fleet locations Amazon GameLift Servers service locations for managed hosting.

INSERT INTO aws.gamelift.locations (
FleetId,
Locations,
region
)
SELECT
'{{ FleetId }}' /* required */,
'{{ Locations }}' /* required */,
'{{ region }}'
RETURNING
fleet_arn,
fleet_id,
location_states
;

DELETE examples

This API works with the following fleet types: EC2, Anywhere, Container 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 Amazon GameLift Servers fleets

DELETE FROM aws.gamelift.locations
WHERE region = '{{ region }}' --required
;