snowflake.core.compute_pool.ComputePoolΒΆ
- class snowflake.core.compute_pool.ComputePool(name: str, min_nodes: int, max_nodes: int, instance_family: str, auto_resume: bool | None = None, comment: str | None = None, state: str | None = None, num_services: int | None = None, num_jobs: int | None = None, auto_suspend_secs: int | None = None, active_nodes: int | None = None, idle_nodes: int | None = None, target_nodes: int | None = None, created_on: datetime | None = None, resumed_on: datetime | None = None, updated_on: datetime | None = None, owner: str | None = None, is_exclusive: bool | None = None, application: str | None = None, budget: str | None = None, error_code: str | None = None, status_message: str | None = None, desired_nodes: int | None = None, desired_nodes_expire_after: datetime | None = None, optimize_for_capacity: bool | None = None, placement_group: str | None = None)ΒΆ
- Bases: - object- A model object representing the ComputePool resource. - Constructs an object of type ComputePool with the provided properties. - Parameters:
- name (str) β A Snowflake object identifier. If the identifier contains spaces or special characters, the entire string must be enclosed in double quotes. Identifiers enclosed in double quotes are also case-sensitive. 
- min_nodes (int) β Minimum number of nodes for the compute pool. 
- max_nodes (int) β Maximum number of nodes for the compute pool. 
- instance_family (str) β Instance family for the compute pool. Use the /api/v2/compute-pools/instance-families endpoint to retrieve available values. 
- auto_resume (bool, optional) β Whether Snowflake automatically resumes the compute pool when any statement that requires the compute pool is submitted. 
- comment (str, optional) β Comment describing the compute pool. 
- state (str, optional) β Current state of the compute pool. Possible values include UNKNOWN, STARTING, IDLE, ACTIVE, STOPPING, SUSPENDED, and RESIZING. 
- num_services (int, optional) β Number of services on the compute pool. 
- num_jobs (int, optional) β Number of jobs on the compute pool. 
- auto_suspend_secs (int, optional) β Number of seconds until the compute pool automatically suspends. 
- active_nodes (int, optional) β Number of currently active nodes on the compute pool. 
- idle_nodes (int, optional) β Number of currently idle nodes on the compute pool. 
- target_nodes (int, optional) β Number of target nodes on the compute pool. 
- created_on (datetime, optional) β Time the compute pool was created. 
- resumed_on (datetime, optional) β Time the compute pool was last resumed. 
- updated_on (datetime, optional) β Time the compute pool was last updated. 
- owner (str, optional) β Identifier for the current owner of the compute pool. 
- is_exclusive (bool, optional) β Whether a compute pool is created exclusively for a Snowflake Native App. 
- application (str, optional) β Name of the Snowflake Native App if the compute pool is created exclusively for the app. 
- budget (str, optional) β The name of the budget monitoring the credit usage of the compute pool. 
- error_code (str, optional) β Current error the compute pool hit if any. 
- status_message (str, optional) β Current status of the compute pool if any. 
- desired_nodes (int, optional) β Number of nodes to maintain on the compute pool 
- desired_nodes_expire_after (datetime, optional) β Time after which the desired nodes on the compute pool will expire. 
- optimize_for_capacity (bool, optional) β Whether the compute pool is optimized for capacity. 
- placement_group (str, optional) β The name of the placement group on the compute pool. 
 
 - Methods - classmethod from_dict(obj: dict) ComputePoolModelΒΆ
- Create an instance of ComputePool from a dict. - This method constructs a ComputePool object from a dictionary with the key-value pairs of its properties. - Parameters:
- obj (dict) β A dictionary whose keys and values correspond to the properties of the resource object. 
- Returns:
- A ComputePool object created using the input dictionary; this will fail if the required properties are missing. 
- Return type:
 
 - to_dict()ΒΆ
- Create a dictionary of the properties from a ComputePool. - This method constructs a dictionary with the key-value entries corresponding to the properties of the ComputePool object. - Returns:
- A dictionary object created using the input model. 
- Return type:
- dict