create_game_session_queue
async
¶
create_game_session_queue(
*,
config_overrides: Optional[AsyncGameLiftClientConfig] = None,
name: Optional[GameSessionQueueName] = None,
timeout_in_seconds: Optional[WholeNumber] = None,
player_latency_policies: Optional[PlayerLatencyPolicyList] = None,
destinations: Optional[GameSessionQueueDestinationList] = None,
filter_configuration: Optional[FilterConfiguration] = None,
priority_configuration: Optional[PriorityConfiguration] = None,
custom_event_data: Optional[QueueCustomEventData] = None,
notification_target: Optional[QueueSnsArnStringModel] = None,
tags: Optional[TagList] = None,
log_configuration: Optional[GameSessionQueueLogConfiguration] = None,
) -> CreateGameSessionQueueOutput
This API works with the following fleet types: EC2, Anywhere, Container
Creates a placement queue that processes requests for new game sessions. A queue finds the best available game server, then prompts it to start a new game session.
A game session queue is configured with a set of destinations (Amazon GameLift Servers fleets or aliases) that determine where the queue can place new game sessions. These destinations can span multiple Amazon Web Services Regions, can use different instance types, and can include both Spot and On-Demand fleets. If the queue includes multi-location fleets, the queue can place game sessions in any of a fleet's remote locations.
You can configure a queue to determine how it selects the best available placement for a new game session. Queues can prioritize placement decisions based on a combination of location, hosting cost, and player latency. You can set up the queue to use the default prioritization or provide alternate instructions using PriorityConfiguration.
Request options
Use this operation to make these common types of requests.
-
Create a queue with the minimum required parameters.
-
Name -
Destinations(This parameter isn't required, but a queue can't make placements without at least one destination.)
-
-
Create a queue with placement notification. Queues that have high placement activity must use a notification system, such as with Amazon Simple Notification Service (Amazon SNS) or Amazon CloudWatch.
-
Required parameters
NameandDestinations -
NotificationTarget
-
-
Create a queue with custom prioritization settings. These custom settings replace the default prioritization configuration for a queue.
-
Required parameters
NameandDestinations -
PriorityConfiguration
-
-
Create a queue with special rules for processing player latency data.
-
Required parameters
NameandDestinations -
PlayerLatencyPolicies
-
-
Create a queue that delivers game session placement insight logs to one or more log destinations.
-
Required parameters
NameandDestinations -
LogConfiguration
-
Results
If successful, this operation returns a new GameSessionQueue object with an assigned queue ARN. Use the queue's name or ARN when submitting new game session requests with StartGameSessionPlacement or StartMatchmaking.
Learn more
Related actions
CreateGameSessionQueue | DescribeGameSessionQueues | UpdateGameSessionQueue | DeleteGameSessionQueue | All APIs by task
Parameters:
-
name(Optional[GameSessionQueueName], default:None) –A descriptive label that is associated with game session queue. Queue names must be unique within each Region.
-
timeout_in_seconds(Optional[WholeNumber], default:None) –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_OUTstatus. If you don't specify a request timeout, the queue uses a default value.The minimum value is 10 and the maximum value is 600.
-
player_latency_policies(Optional[PlayerLatencyPolicyList], default:None) –A set of policies that enforce a sliding cap on player latency when processing game sessions placement requests. Use multiple policies to gradually relax the cap over time if Amazon GameLift Servers can't make a placement. Policies are evaluated in order starting with the lowest maximum latency value.
-
destinations(Optional[GameSessionQueueDestinationList], default:None) –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.
-
filter_configuration(Optional[FilterConfiguration], default:None) –A list of locations where a queue is allowed to place new game sessions. Locations are specified in the form of Amazon Web Services Region codes, such as
us-west-2. If this parameter is not set, game sessions can be placed in any queue location. -
priority_configuration(Optional[PriorityConfiguration], default:None) –Custom settings to use when prioritizing destinations and locations for game session placements. This configuration replaces the default prioritization process. Priority types that are not explicitly named will be automatically applied at the end of the prioritization process.
-
custom_event_data(Optional[QueueCustomEventData], default:None) –Information to be added to all events that are related to this game session queue.
-
notification_target(Optional[QueueSnsArnStringModel], default:None) –An SNS topic ARN that is set up to receive game session placement notifications. See Setting up notifications for game session placement.
-
tags(Optional[TagList], default:None) –A list of labels to assign to the new game session queue resource. Tags are developer-defined key-value pairs. Tagging Amazon Web Services resources is useful for resource management, access management and cost allocation. For more information, see Tagging Amazon Web Services Resources in the Amazon Web Services General Reference.
-
log_configuration(Optional[GameSessionQueueLogConfiguration], default:None) –An optional configuration that delivers game session placement insight logs to one or more destinations of your choice. Use these logs to diagnose why a game session placement is
FULFILLED,CANCELLED,TIMED_OUT, orFAILED, which locations were evaluated, and the latency and cost factors that influenced each decision.
Raises:
-
InternalServiceException–The service encountered an unrecoverable internal failure while processing the request. Clients can retry such requests immediately or after a waiting period.
-
InvalidRequestException–One or more parameter values in the request are invalid. Correct the invalid parameter values before retrying.
-
LimitExceededException–The requested operation would cause the resource to exceed the allowed service limit. Resolve the issue before retrying.
-
NotFoundException–The requested resource was not found. The resource was either not created yet or deleted.
-
TaggingFailedException–The requested tagging operation did not succeed. This may be due to invalid tag format or the maximum tag limit may have been exceeded. Resolve the issue before retrying.
-
UnauthorizedException–The client failed authentication. Clients should not retry such requests.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_gamelift/_services/async_game_lift.py
1798 1799 1800 1801 1802 1803 1804 1805 1806 1807 1808 1809 1810 1811 1812 1813 1814 1815 1816 1817 1818 1819 1820 1821 1822 1823 1824 1825 1826 1827 1828 1829 1830 1831 1832 1833 1834 1835 1836 1837 1838 1839 1840 1841 1842 1843 1844 1845 1846 1847 1848 1849 1850 1851 1852 1853 1854 1855 1856 1857 1858 1859 1860 1861 1862 1863 1864 1865 1866 1867 1868 1869 1870 1871 1872 1873 1874 1875 1876 1877 1878 1879 1880 1881 1882 1883 1884 1885 1886 1887 1888 1889 1890 1891 1892 1893 1894 1895 1896 1897 1898 1899 1900 1901 1902 1903 1904 1905 1906 1907 1908 1909 1910 1911 1912 1913 1914 1915 1916 1917 1918 1919 1920 1921 1922 1923 1924 1925 1926 1927 1928 1929 1930 1931 1932 1933 1934 1935 1936 1937 1938 | |