Snowball.Client.
list_clusters
(**kwargs)¶Returns an array of ClusterListEntry
objects of the specified length. Each ClusterListEntry
object contains a cluster's state, a cluster's ID, and other important status information.
See also: AWS API Documentation
Request Syntax
response = client.list_clusters(
MaxResults=123,
NextToken='string'
)
ClusterListEntry
objects to return.ClusterListEntry
objects, you have the option of specifying NextToken
as the starting point for your returned list.dict
Response Syntax
{
'ClusterListEntries': [
{
'ClusterId': 'string',
'ClusterState': 'AwaitingQuorum'|'Pending'|'InUse'|'Complete'|'Cancelled',
'CreationDate': datetime(2015, 1, 1),
'Description': 'string'
},
],
'NextToken': 'string'
}
Response Structure
(dict) --
ClusterListEntries (list) --
Each ClusterListEntry
object contains a cluster's state, a cluster's ID, and other important status information.
(dict) --
Contains a cluster's state, a cluster's ID, and other important information.
ClusterId (string) --
The 39-character ID for the cluster that you want to list, for example CID123e4567-e89b-12d3-a456-426655440000
.
ClusterState (string) --
The current state of this cluster. For information about the state of a specific node, see JobListEntry$JobState.
CreationDate (datetime) --
The creation date for this cluster.
Description (string) --
Defines an optional description of the cluster, for example Environmental Data Cluster-01
.
NextToken (string) --
HTTP requests are stateless. If you use the automatically generated NextToken
value in your next ClusterListEntry
call, your list of returned clusters will start from this point in the array.
Exceptions
Snowball.Client.exceptions.InvalidNextTokenException
Examples
Returns an array of ClusterListEntry objects of the specified length. Each ClusterListEntry object contains a cluster's state, a cluster's ID, and other important status information.
response = client.list_clusters(
)
print(response)
Expected Output:
{
'ClusterListEntries': [
{
'ClusterId': 'CID123e4567-e89b-12d3-a456-426655440000',
'ClusterState': 'Pending',
'CreationDate': datetime(2016, 11, 30, 3, 11, 57, 2, 335, 0),
'Description': 'MyCluster',
},
],
'ResponseMetadata': {
'...': '...',
},
}