aistore.sdk.cluster
Module Contents
Classes
Data
API
A class representing a cluster bound to an AIS client.
Client this cluster uses to make requests
Make the HTTP request to fetch a node’s log.
Parameters:
Daemon ID of the node.
Log severity string value.
If True, fetch all rotated logs as TAR.GZ archive.
Get logs from all nodes of a given role.
Parameters:
Log severity level (default: LogSeverity.INFO).
Node filter (default: NodeFilter.TARGET).
Returns: Dict[str, str]
Dict[str, str]: Mapping of node ID to log content.
Returns state of AIS cluster, including the detailed information about its nodes.
Returns: Smap
aistore.sdk.types.Smap: Smap containing cluster information
Raises:
requests.RequestException: “There was an ambiguous exception that occurred while handling…”requests.ConnectionError: Connection errorrequests.ConnectionTimeout: Timed out connecting to AIStorerequests.ReadTimeout: Timed out waiting response from AIStore
Get the current log from a specific cluster node (target or proxy).
Parameters:
Daemon ID of the node (e.g., “hHQZBnBQ”).
Log severity level (default: LogSeverity.INFO).
Returns: str
Current log content as text.
Download a TAR.GZ archive of all rotated logs from a specific node.
TODO: stream the archive instead of loading into memory for large logs.
Parameters:
Daemon ID of the node (e.g., “hHQZBnBQ”).
Log severity level (default: LogSeverity.INFO).
Returns: bytes
TAR.GZ archive containing all rotated log files. Loaded into memory; typically ~5MB compressed per node.
Retrieves the raw performance and status data from each target node in the AIStore cluster.
Returns: Dict
A dictionary where each key is the ID of a target node and each value is the raw AIS performance/status JSON returned by that node (for more information, see https://aistore.nvidia.com/docs/monitoring-metrics#target-metrics).
Raises:
requests.RequestException: If there’s an ambiguous exception while processing the requestrequests.ConnectionError: If there’s a connection error with the clusterrequests.ConnectionTimeout: If the connection to the cluster times outrequests.ReadTimeout: If the timeout is reached while awaiting a response from the cluster
Returns: URL of primary proxy
Returns: UUID of AIStore Cluster
Checks if cluster is ready or still setting up.
Returns: bool
True if cluster is ready, or false if cluster is still setting up
Returns list of buckets in AIStore cluster.
Parameters:
Provider of bucket (one of “ais”, “aws”, “gcp”, …). Defaults to “ais”. Empty provider returns buckets of all providers.
Returns:
List[BucketModel]: A list of buckets
Raises:
requests.RequestException: “There was an ambiguous exception that occurred while handling…”requests.ConnectionError: Connection errorrequests.ConnectionTimeout: Timed out connecting to AIStorerequests.ReadTimeout: Timed out waiting response from AIStore
Lists ETLs filtered by their stages.
Parameters:
List of stages to filter ETLs by. Defaults to [“running”].
Returns: List[ETLInfo]
List[ETLInfo]: A list of details on ETLs matching the specified stages
List the status of jobs on the cluster
Parameters:
Only show jobs of a particular type
Limit to jobs on a specific target node
Returns: List[JobStatus]
List of JobStatus objects
List the currently running jobs on the cluster
Parameters:
Only show jobs of a particular type
Limit to jobs on a specific target node
Returns: List[str]
List of jobs in the format job_kind[job_id]