DeadlineCloud / Client / batch_get_session
batch_get_session¶
- DeadlineCloud.Client.batch_get_session(**kwargs)¶
Retrieves multiple sessions in a single request. This is a batch version of the
GetSessionAPI.The result of getting each session is reported individually in the response. Because the batch request can result in a combination of successful and unsuccessful actions, you should check for batch errors even when the call returns an HTTP status code of 200.
See also: AWS API Documentation
Request Syntax
response = client.batch_get_session( identifiers=[ { 'farmId': 'string', 'queueId': 'string', 'jobId': 'string', 'sessionId': 'string' }, ] )
- Parameters:
identifiers (list) –
[REQUIRED]
The list of session identifiers to retrieve. You can specify up to 100 identifiers per request.
(dict) –
The identifiers for a session.
farmId (string) – [REQUIRED]
The farm ID of the session.
queueId (string) – [REQUIRED]
The queue ID of the session.
jobId (string) – [REQUIRED]
The job ID of the session.
sessionId (string) – [REQUIRED]
The session ID.
- Return type:
dict
- Returns:
Response Syntax
{ 'sessions': [ { 'farmId': 'string', 'queueId': 'string', 'jobId': 'string', 'sessionId': 'string', 'fleetId': 'string', 'workerId': 'string', 'startedAt': datetime(2015, 1, 1), 'lifecycleStatus': 'STARTED'|'UPDATE_IN_PROGRESS'|'UPDATE_SUCCEEDED'|'UPDATE_FAILED'|'ENDED', 'endedAt': datetime(2015, 1, 1), 'targetLifecycleStatus': 'ENDED', 'updatedAt': datetime(2015, 1, 1), 'updatedBy': 'string', 'log': { 'logDriver': 'string', 'options': { 'string': 'string' }, 'parameters': { 'string': 'string' }, 'error': 'string' }, 'hostProperties': { 'ipAddresses': { 'ipV4Addresses': [ 'string', ], 'ipV6Addresses': [ 'string', ] }, 'hostName': 'string', 'ec2InstanceArn': 'string', 'ec2InstanceType': 'string' }, 'workerLog': { 'logDriver': 'string', 'options': { 'string': 'string' }, 'parameters': { 'string': 'string' }, 'error': 'string' } }, ], 'errors': [ { 'farmId': 'string', 'queueId': 'string', 'jobId': 'string', 'sessionId': 'string', 'code': 'InternalServerErrorException'|'ResourceNotFoundException'|'ValidationException', 'message': 'string' }, ] }
Response Structure
(dict) –
sessions (list) –
A list of sessions that were successfully retrieved.
(dict) –
The details of a session returned in a batch get operation.
farmId (string) –
The farm ID of the session.
queueId (string) –
The queue ID of the session.
jobId (string) –
The job ID of the session.
sessionId (string) –
The session ID.
fleetId (string) –
The fleet ID of the session.
workerId (string) –
The worker ID of the session.
startedAt (datetime) –
The date and time the resource started running.
lifecycleStatus (string) –
The life cycle status of the session.
endedAt (datetime) –
The date and time the resource ended running.
targetLifecycleStatus (string) –
The target life cycle status for the session.
updatedAt (datetime) –
The date and time the resource was updated.
updatedBy (string) –
The user or system that updated this resource.
log (dict) –
The session log.
logDriver (string) –
The log drivers for worker related logs.
options (dict) –
The options for a log driver.
(string) –
(string) –
parameters (dict) –
The parameters for the log configuration.
(string) –
(string) –
error (string) –
The log configuration error details.
hostProperties (dict) –
The host properties for the session.
ipAddresses (dict) –
The IP address of the host.
ipV4Addresses (list) –
The IpV4 address of the network.
(string) –
ipV6Addresses (list) –
The IpV6 address for the network and node component.
(string) –
hostName (string) –
The host name.
ec2InstanceArn (string) –
The ARN of the host EC2 instance.
ec2InstanceType (string) –
The instance type of the host EC2 instance.
workerLog (dict) –
The worker log for the session.
logDriver (string) –
The log drivers for worker related logs.
options (dict) –
The options for a log driver.
(string) –
(string) –
parameters (dict) –
The parameters for the log configuration.
(string) –
(string) –
error (string) –
The log configuration error details.
errors (list) –
A list of errors for sessions that could not be retrieved.
(dict) –
The error details for a session that could not be retrieved in a batch get operation.
farmId (string) –
The farm ID of the session that could not be retrieved.
queueId (string) –
The queue ID of the session that could not be retrieved.
jobId (string) –
The job ID of the session that could not be retrieved.
sessionId (string) –
The session ID of the session that could not be retrieved.
code (string) –
The error code.
message (string) –
The error message.
Exceptions
DeadlineCloud.Client.exceptions.AccessDeniedExceptionDeadlineCloud.Client.exceptions.InternalServerErrorExceptionDeadlineCloud.Client.exceptions.ThrottlingExceptionDeadlineCloud.Client.exceptions.ValidationException