list_compute
¶
list_compute(
*,
config_overrides: Optional[GameLiftClientConfig] = None,
fleet_id: Optional[FleetIdOrArn] = None,
location: Optional[LocationStringModel] = None,
container_group_definition_name: Optional[ContainerGroupDefinitionNameOrArn] = None,
compute_status: Optional[ListComputeInputStatus] = None,
limit: Optional[PositiveInteger] = None,
next_token: Optional[NonZeroAndMaxString] = None,
) -> ListComputeOutput
This API works with the following fleet types: EC2, Anywhere, Container
Retrieves information on the compute resources in an Amazon GameLift Servers fleet. Use the pagination parameters to retrieve results in a set of sequential pages.
Request options
-
Retrieve a list of all computes in a fleet. Specify a fleet ID.
-
Retrieve a list of all computes in a specific fleet location. Specify a fleet ID and location.
Results
If successful, this operation returns information on a set of computes. Depending on the type of fleet, the result includes the following information:
-
For a managed EC2 fleet (compute type
EC2), this operation returns information about the EC2 instance. Compute names are EC2 instance IDs. -
For an Anywhere fleet (compute type
ANYWHERE), this operation returns compute names and details from when the compute was registered withRegisterCompute. This includesGameLiftServiceSdkEndpointorGameLiftAgentEndpoint.
Parameters:
-
fleet_id(Optional[FleetIdOrArn], default:None) –A unique identifier for the fleet to retrieve compute resources for.
-
location(Optional[LocationStringModel], default:None) –The name of a location to retrieve compute resources for. For an Amazon GameLift Servers Anywhere fleet, use a custom location. For a managed fleet, provide a Amazon Web Services Region or Local Zone code (for example:
us-west-2orus-west-2-lax-1). -
container_group_definition_name(Optional[ContainerGroupDefinitionNameOrArn], default:None) –For computes in a managed container fleet, the name of the deployed container group definition.
-
compute_status(Optional[ListComputeInputStatus], default:None) –The status of computes in a managed container fleet, based on the success of the latest update deployment.
-
ACTIVE-- The compute is deployed with the correct container definitions. It is ready to process game servers and host game sessions. -
IMPAIRED-- An update deployment to the compute failed, and the compute is deployed with incorrect container definitions.
-
-
limit(Optional[PositiveInteger], default:None) –The maximum number of results to return. Use this parameter with
NextTokento get results as a set of sequential pages. -
next_token(Optional[NonZeroAndMaxString], default:None) –A token that indicates the start of the next sequential page of results. Use the token that is returned with a previous call to this operation. To start at the beginning of the result set, do not specify a value.
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.
-
UnauthorizedException–The client failed authentication. Clients should not retry such requests.
-
UnsupportedRegionException–The requested operation is not supported in the Region specified.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_gamelift/_services/game_lift.py
6323 6324 6325 6326 6327 6328 6329 6330 6331 6332 6333 6334 6335 6336 6337 6338 6339 6340 6341 6342 6343 6344 6345 6346 6347 6348 6349 6350 6351 6352 6353 6354 6355 6356 6357 6358 6359 6360 6361 6362 6363 6364 6365 6366 6367 6368 6369 6370 6371 6372 6373 6374 6375 6376 6377 6378 6379 6380 6381 6382 6383 6384 6385 6386 6387 6388 6389 6390 6391 6392 6393 6394 6395 6396 6397 6398 6399 6400 6401 6402 6403 6404 6405 | |