# ComputePool

[Snowflake Documentation](https://docs.snowflake.com/en/sql-reference/sql/create-compute-pool)

A compute pool is a group of compute resources in Snowflake that can be used to execute SQL queries.

## Examples

### Python

```python
compute_pool = ComputePool(
    name="some_compute_pool",
    owner="ACCOUNTADMIN",
    min_nodes=2,
    max_nodes=10,
    instance_family="CPU_X64_S",
    auto_resume=True,
    initially_suspended=False,
    auto_suspend_secs=1800,
    comment="Example compute pool"
)
```

### YAML

```yaml
compute_pools:
  - name: some_compute_pool
    owner: ACCOUNTADMIN
    min_nodes: 2
    max_nodes: 10
    instance_family: CPU_X64_S
    auto_resume: true
    initially_suspended: false
    auto_suspend_secs: 1800
    comment: Example compute pool
```

## Fields

* `name` (string, required) - The unique name of the compute pool.
* `owner` (string or [Role](/titan-core/resources/role.md)) - The owner of the compute pool. Defaults to "ACCOUNTADMIN".
* `min_nodes` (int) - The minimum number of nodes in the compute pool.
* `max_nodes` (int) - The maximum number of nodes in the compute pool.
* `instance_family` (string or [InstanceFamily](https://github.com/Titan-Systems/titan/blob/main/docs/resources/instance_family.md)) - The family of instances to use for the compute nodes.
* `auto_resume` (bool) - Whether the compute pool should automatically resume when queries are submitted. Defaults to True.
* `initially_suspended` (bool) - Whether the compute pool should start in a suspended state.
* `auto_suspend_secs` (int) - The number of seconds of inactivity after which the compute pool should automatically suspend. Defaults to 3600.
* `comment` (string) - An optional comment about the compute pool.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://titan-core.gitbook.io/titan-core/resources/compute_pool.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
