Skip to main content

Warehouse

View as Markdown

EndpointInfo object

idstring

unique identifier for warehouse

namestring

Logical name for the cluster.

Supported values:

  • Must be unique within an org.
  • Must be less than 100 characters.
cluster_sizestring

Size of the clusters allocated for this warehouse. Increasing the size of a spark cluster allows you to run larger queries on it. If you want to increase the number of concurrent queries, please tune max_num_clusters.

Supported values:

  • 2X-Small
  • X-Small
  • Small
  • Medium
  • Large
  • X-Large
  • 2X-Large
  • 3X-Large
  • 4X-Large
  • 5X-Large
min_num_clustersint32

Minimum number of available clusters that will be maintained for this SQL warehouse. Increasing this will ensure that a larger number of clusters are always running and therefore may reduce the cold start time for new queries. This is similar to reserved vs. revocable cores in a resource manager.

Supported values:

  • Must be > 0
  • Must be <= min(max_num_clusters, 30)

Defaults to 1

Default: 1

max_num_clustersint32

Maximum number of clusters that the autoscaler will create to handle concurrent queries.

Supported values:

  • Must be >= min_num_clusters
  • Must be <= 40.

Defaults to min_clusters if unset.

auto_stop_minsint32

The amount of time in minutes that a SQL warehouse must be idle (i.e., no RUNNING queries) before it is automatically stopped.

Supported values:

  • Must be == 0 or >= 10 mins
  • 0 indicates no autostop.

Defaults to 120 mins

Default: 120

creator_namestring

warehouse creator name

instance_profile_arnstring

Deprecated. Instance profile used to pass IAM role to the cluster

tagsobject

A set of key-value pairs that will be tagged on all resources (e.g., AWS instances and EBS volumes) associated with this SQL warehouse.

Supported values:

  • Number of tags < 45.
Show child attributesHide child attributes
custom_tagsarray of object
Show child attributesHide child attributes
keystring
valuestring
spot_instance_policystring

Configurations whether the endpoint should use spot instances.

Default: COST_OPTIMIZED

Values: POLICY_UNSPECIFIED, COST_OPTIMIZED, RELIABILITY_OPTIMIZED

enable_photonboolean

Configures whether the warehouse should use Photon optimized clusters.

Defaults to true.

channelobject

Channel Details

Show child attributesHide child attributes
namestring

Values: CHANNEL_NAME_UNSPECIFIED, CHANNEL_NAME_PREVIEW, CHANNEL_NAME_CURRENT, CHANNEL_NAME_PREVIOUS, CHANNEL_NAME_CUSTOM

dbsql_versionstring
enable_serverless_computeboolean

Configures whether the warehouse should use serverless compute

warehouse_typestring

Warehouse type: PRO or CLASSIC. If you want to use serverless compute, you must set to PRO and also set the field enable_serverless_compute to true.

Values: TYPE_UNSPECIFIED, CLASSIC, PRO

num_clustersint32

current number of clusters running for the service

num_active_sessionsint64

Deprecated. current number of active sessions for the warehouse

statestring

state of the endpoint

Values: STARTING, RUNNING, STOPPING, STOPPED, DELETING, DELETED

jdbc_urlstring

the jdbc connection string for this warehouse

odbc_paramsobject

ODBC parameters for the SQL warehouse

Show child attributesHide child attributes
hostnamestring
pathstring
protocolstring
portint32
healthobject

Optional health status. Assume the warehouse is healthy if this field is not set.

Show child attributesHide child attributes
statusstring

Health status of the endpoint.

Values: STATUS_UNSPECIFIED, HEALTHY, DEGRADED, FAILED

messagestring

Deprecated. split into summary and details for security

failure_reasonobject

The reason for failure to bring up clusters for this warehouse. This is available when status is 'FAILED' and sometimes when it is DEGRADED.

Show child attributesHide child attributes
codestring

status code indicating why the cluster was terminated

Values: UNKNOWN, USER_REQUEST, JOB_FINISHED, INACTIVITY, CLOUD_PROVIDER_SHUTDOWN, COMMUNICATION_LOST, CLOUD_PROVIDER_LAUNCH_FAILURE, INIT_SCRIPT_FAILURE, SPARK_STARTUP_FAILURE, INVALID_ARGUMENT, UNEXPECTED_LAUNCH_FAILURE, INTERNAL_ERROR, INSTANCE_UNREACHABLE, REQUEST_REJECTED, TRIAL_EXPIRED, DRIVER_UNREACHABLE, SPARK_ERROR, DRIVER_UNRESPONSIVE, METASTORE_COMPONENT_UNHEALTHY, DBFS_COMPONENT_UNHEALTHY, EXECUTION_COMPONENT_UNHEALTHY, AZURE_RESOURCE_MANAGER_THROTTLING, AZURE_RESOURCE_PROVIDER_THROTTLING, NETWORK_CONFIGURATION_FAILURE, CONTAINER_LAUNCH_FAILURE, INSTANCE_POOL_CLUSTER_FAILURE, SKIPPED_SLOW_NODES, ATTACH_PROJECT_FAILURE, UPDATE_INSTANCE_PROFILE_FAILURE, DATABASE_CONNECTION_FAILURE, REQUEST_THROTTLED, SELF_BOOTSTRAP_FAILURE, GLOBAL_INIT_SCRIPT_FAILURE, SLOW_IMAGE_DOWNLOAD, INVALID_SPARK_IMAGE, NPIP_TUNNEL_TOKEN_FAILURE, HIVE_METASTORE_PROVISIONING_FAILURE, AZURE_INVALID_DEPLOYMENT_TEMPLATE, AZURE_UNEXPECTED_DEPLOYMENT_TEMPLATE_FAILURE, SUBNET_EXHAUSTED_FAILURE, BOOTSTRAP_TIMEOUT, STORAGE_DOWNLOAD_FAILURE, CONTROL_PLANE_REQUEST_FAILURE, BOOTSTRAP_TIMEOUT_CLOUD_PROVIDER_EXCEPTION, AWS_INSUFFICIENT_INSTANCE_CAPACITY_FAILURE, DOCKER_IMAGE_PULL_FAILURE, AZURE_VNET_CONFIGURATION_FAILURE, NPIP_TUNNEL_SETUP_FAILURE, AWS_AUTHORIZATION_FAILURE, NEPHOS_RESOURCE_MANAGEMENT, STS_CLIENT_SETUP_FAILURE, SECURITY_DAEMON_REGISTRATION_EXCEPTION, AWS_REQUEST_LIMIT_EXCEEDED, AWS_INSUFFICIENT_FREE_ADDRESSES_IN_SUBNET_FAILURE, AWS_UNSUPPORTED_FAILURE, AZURE_QUOTA_EXCEEDED_EXCEPTION, AZURE_OPERATION_NOT_ALLOWED_EXCEPTION, NFS_MOUNT_FAILURE, K8S_AUTOSCALING_FAILURE, K8S_DBR_CLUSTER_LAUNCH_TIMEOUT, SPARK_IMAGE_DOWNLOAD_FAILURE, AZURE_VM_EXTENSION_FAILURE, WORKSPACE_CANCELLED_ERROR, AWS_MAX_SPOT_INSTANCE_COUNT_EXCEEDED_FAILURE, TEMPORARILY_UNAVAILABLE, WORKER_SETUP_FAILURE, IP_EXHAUSTION_FAILURE, GCP_QUOTA_EXCEEDED, CLOUD_PROVIDER_RESOURCE_STOCKOUT, GCP_SERVICE_ACCOUNT_DELETED, AZURE_BYOK_KEY_PERMISSION_FAILURE, SPOT_INSTANCE_TERMINATION, AZURE_EPHEMERAL_DISK_FAILURE, ABUSE_DETECTED, IMAGE_PULL_PERMISSION_DENIED, WORKSPACE_CONFIGURATION_ERROR, SECRET_RESOLUTION_ERROR, UNSUPPORTED_INSTANCE_TYPE, CLOUD_PROVIDER_DISK_SETUP_FAILURE, SSH_BOOTSTRAP_FAILURE, AWS_INACCESSIBLE_KMS_KEY_FAILURE, INIT_CONTAINER_NOT_FINISHED, SPARK_IMAGE_DOWNLOAD_THROTTLED, SPARK_IMAGE_NOT_FOUND, CLUSTER_OPERATION_THROTTLED, CLUSTER_OPERATION_TIMEOUT, SERVERLESS_LONG_RUNNING_TERMINATED, AZURE_PACKED_DEPLOYMENT_PARTIAL_FAILURE, INVALID_WORKER_IMAGE_FAILURE, WORKSPACE_UPDATE, INVALID_AWS_PARAMETER, DRIVER_OUT_OF_DISK, DRIVER_OUT_OF_MEMORY, DRIVER_LAUNCH_TIMEOUT, DRIVER_UNEXPECTED_FAILURE, UNEXPECTED_POD_RECREATION, GCP_INACCESSIBLE_KMS_KEY_FAILURE, GCP_KMS_KEY_PERMISSION_DENIED, DRIVER_EVICTION, USER_INITIATED_VM_TERMINATION, GCP_IAM_TIMEOUT, AWS_RESOURCE_QUOTA_EXCEEDED, CLOUD_ACCOUNT_SETUP_FAILURE, AWS_INVALID_KEY_PAIR, DRIVER_POD_CREATION_FAILURE, MAINTENANCE_MODE, INTERNAL_CAPACITY_FAILURE, EXECUTOR_POD_UNSCHEDULED, STORAGE_DOWNLOAD_FAILURE_SLOW, STORAGE_DOWNLOAD_FAILURE_THROTTLED, DYNAMIC_SPARK_CONF_SIZE_EXCEEDED, AWS_INSTANCE_PROFILE_UPDATE_FAILURE, INSTANCE_POOL_NOT_FOUND, INSTANCE_POOL_MAX_CAPACITY_REACHED, AWS_INVALID_KMS_KEY_STATE, GCP_INSUFFICIENT_CAPACITY, GCP_API_RATE_QUOTA_EXCEEDED, GCP_RESOURCE_QUOTA_EXCEEDED, GCP_IP_SPACE_EXHAUSTED, GCP_SERVICE_ACCOUNT_ACCESS_DENIED, GCP_SERVICE_ACCOUNT_NOT_FOUND, GCP_FORBIDDEN, GCP_NOT_FOUND, RESOURCE_USAGE_BLOCKED, DATA_ACCESS_CONFIG_CHANGED, ACCESS_TOKEN_FAILURE, INVALID_INSTANCE_PLACEMENT_PROTOCOL, BUDGET_POLICY_RESOLUTION_FAILURE, IN_PENALTY_BOX, DISASTER_RECOVERY_REPLICATION, BOOTSTRAP_TIMEOUT_DUE_TO_MISCONFIG, INSTANCE_UNREACHABLE_DUE_TO_MISCONFIG, STORAGE_DOWNLOAD_FAILURE_DUE_TO_MISCONFIG, CONTROL_PLANE_REQUEST_FAILURE_DUE_TO_MISCONFIG, CLOUD_PROVIDER_LAUNCH_FAILURE_DUE_TO_MISCONFIG, GCP_SUBNET_NOT_READY, CLOUD_OPERATION_CANCELLED, CLOUD_PROVIDER_INSTANCE_NOT_LAUNCHED, GCP_TRUSTED_IMAGE_PROJECTS_VIOLATED, BUDGET_POLICY_LIMIT_ENFORCEMENT_ACTIVATED, EOS_SPARK_IMAGE, NO_MATCHED_K8S, LAZY_ALLOCATION_TIMEOUT, DRIVER_NODE_UNREACHABLE, SECRET_CREATION_FAILURE, POD_SCHEDULING_FAILURE, POD_ASSIGNMENT_FAILURE, ALLOCATION_TIMEOUT, ALLOCATION_TIMEOUT_NO_UNALLOCATED_CLUSTERS, ALLOCATION_TIMEOUT_NO_MATCHED_CLUSTERS, ALLOCATION_TIMEOUT_NO_READY_CLUSTERS, ALLOCATION_TIMEOUT_NO_WARMED_UP_CLUSTERS, ALLOCATION_TIMEOUT_NODE_DAEMON_NOT_READY, ALLOCATION_TIMEOUT_NO_HEALTHY_CLUSTERS, NETVISOR_SETUP_TIMEOUT, NO_MATCHED_K8S_TESTING_TAG, CLOUD_PROVIDER_RESOURCE_STOCKOUT_DUE_TO_MISCONFIG, GKE_BASED_CLUSTER_TERMINATION, ALLOCATION_TIMEOUT_NO_HEALTHY_AND_WARMED_UP_CLUSTERS, DOCKER_INVALID_OS_EXCEPTION, DOCKER_CONTAINER_CREATION_EXCEPTION, DOCKER_IMAGE_TOO_LARGE_FOR_INSTANCE_EXCEPTION, DNS_RESOLUTION_ERROR, GCP_DENIED_BY_ORG_POLICY, SECRET_PERMISSION_DENIED, NETWORK_CHECK_NIC_FAILURE, NETWORK_CHECK_DNS_SERVER_FAILURE, NETWORK_CHECK_STORAGE_FAILURE, NETWORK_CHECK_METADATA_ENDPOINT_FAILURE, NETWORK_CHECK_CONTROL_PLANE_FAILURE, NETWORK_CHECK_MULTIPLE_COMPONENTS_FAILURE, DRIVER_UNHEALTHY, USAGE_POLICY_ENTITLEMENT_DENIED, K8S_ACTIVE_POD_QUOTA_EXCEEDED, CLOUD_ACCOUNT_POD_QUOTA_EXCEEDED, NETWORK_CHECK_NIC_FAILURE_DUE_TO_MISCONFIG, NETWORK_CHECK_DNS_SERVER_FAILURE_DUE_TO_MISCONFIG, NETWORK_CHECK_STORAGE_FAILURE_DUE_TO_MISCONFIG, NETWORK_CHECK_METADATA_ENDPOINT_FAILURE_DUE_TO_MISCONFIG, NETWORK_CHECK_CONTROL_PLANE_FAILURE_DUE_TO_MISCONFIG, NETWORK_CHECK_MULTIPLE_COMPONENTS_FAILURE_DUE_TO_MISCONFIG, DBR_IMAGE_RESOLUTION_FAILURE, CONTROL_PLANE_CONNECTION_FAILURE, CONTROL_PLANE_CONNECTION_FAILURE_DUE_TO_MISCONFIG, RATE_LIMITED, MTLS_PORT_CONNECTIVITY_FAILURE, HIVEMETASTORE_CONNECTIVITY_FAILURE

typestring

type of the termination

Values: SUCCESS, CLIENT_ERROR, SERVICE_FAULT, CLOUD_FAILURE

parametersobject

list of parameters that provide additional information about why the cluster was terminated

summarystring

A short summary of the health status in case of degraded/failed warehouses.

detailsstring

Details about errors that are causing current degraded/failed status.

Get GA

GET /api/2.0/sql/warehouses/{id}

Gets the information for a single SQL warehouse.

API scopes: sql

Parameters

idstringpath

Required. Id of the SQL warehouse.

Response

idstring

unique identifier for warehouse

namestring

Logical name for the cluster.

Supported values:

  • Must be unique within an org.
  • Must be less than 100 characters.
cluster_sizestring

Size of the clusters allocated for this warehouse. Increasing the size of a spark cluster allows you to run larger queries on it. If you want to increase the number of concurrent queries, please tune max_num_clusters.

Supported values:

  • 2X-Small
  • X-Small
  • Small
  • Medium
  • Large
  • X-Large
  • 2X-Large
  • 3X-Large
  • 4X-Large
  • 5X-Large
min_num_clustersint32

Minimum number of available clusters that will be maintained for this SQL warehouse. Increasing this will ensure that a larger number of clusters are always running and therefore may reduce the cold start time for new queries. This is similar to reserved vs. revocable cores in a resource manager.

Supported values:

  • Must be > 0
  • Must be <= min(max_num_clusters, 30)

Defaults to 1

Default: 1

max_num_clustersint32

Maximum number of clusters that the autoscaler will create to handle concurrent queries.

Supported values:

  • Must be >= min_num_clusters
  • Must be <= 40.

Defaults to min_clusters if unset.

auto_stop_minsint32

The amount of time in minutes that a SQL warehouse must be idle (i.e., no RUNNING queries) before it is automatically stopped.

Supported values:

  • Must be == 0 or >= 10 mins
  • 0 indicates no autostop.

Defaults to 120 mins

Default: 120

creator_namestring

warehouse creator name

instance_profile_arnstring

Deprecated. Instance profile used to pass IAM role to the cluster

tagsobject

A set of key-value pairs that will be tagged on all resources (e.g., AWS instances and EBS volumes) associated with this SQL warehouse.

Supported values:

  • Number of tags < 45.
Show child attributesHide child attributes
custom_tagsarray of object
Show child attributesHide child attributes
keystring
valuestring
spot_instance_policystring

Configurations whether the endpoint should use spot instances.

Default: COST_OPTIMIZED

Values: POLICY_UNSPECIFIED, COST_OPTIMIZED, RELIABILITY_OPTIMIZED

enable_photonboolean

Configures whether the warehouse should use Photon optimized clusters.

Defaults to true.

channelobject

Channel Details

Show child attributesHide child attributes
namestring

Values: CHANNEL_NAME_UNSPECIFIED, CHANNEL_NAME_PREVIEW, CHANNEL_NAME_CURRENT, CHANNEL_NAME_PREVIOUS, CHANNEL_NAME_CUSTOM

dbsql_versionstring
enable_serverless_computeboolean

Configures whether the warehouse should use serverless compute

warehouse_typestring

Warehouse type: PRO or CLASSIC. If you want to use serverless compute, you must set to PRO and also set the field enable_serverless_compute to true.

Values: TYPE_UNSPECIFIED, CLASSIC, PRO

num_clustersint32

current number of clusters running for the service

num_active_sessionsint64

Deprecated. current number of active sessions for the warehouse

statestring

state of the endpoint

Values: STARTING, RUNNING, STOPPING, STOPPED, DELETING, DELETED

jdbc_urlstring

the jdbc connection string for this warehouse

odbc_paramsobject

ODBC parameters for the SQL warehouse

Show child attributesHide child attributes
hostnamestring
pathstring
protocolstring
portint32
healthobject

Optional health status. Assume the warehouse is healthy if this field is not set.

Show child attributesHide child attributes
statusstring

Health status of the endpoint.

Values: STATUS_UNSPECIFIED, HEALTHY, DEGRADED, FAILED

messagestring

Deprecated. split into summary and details for security

failure_reasonobject

The reason for failure to bring up clusters for this warehouse. This is available when status is 'FAILED' and sometimes when it is DEGRADED.

Show child attributesHide child attributes
codestring

status code indicating why the cluster was terminated

Values: UNKNOWN, USER_REQUEST, JOB_FINISHED, INACTIVITY, CLOUD_PROVIDER_SHUTDOWN, COMMUNICATION_LOST, CLOUD_PROVIDER_LAUNCH_FAILURE, INIT_SCRIPT_FAILURE, SPARK_STARTUP_FAILURE, INVALID_ARGUMENT, UNEXPECTED_LAUNCH_FAILURE, INTERNAL_ERROR, INSTANCE_UNREACHABLE, REQUEST_REJECTED, TRIAL_EXPIRED, DRIVER_UNREACHABLE, SPARK_ERROR, DRIVER_UNRESPONSIVE, METASTORE_COMPONENT_UNHEALTHY, DBFS_COMPONENT_UNHEALTHY, EXECUTION_COMPONENT_UNHEALTHY, AZURE_RESOURCE_MANAGER_THROTTLING, AZURE_RESOURCE_PROVIDER_THROTTLING, NETWORK_CONFIGURATION_FAILURE, CONTAINER_LAUNCH_FAILURE, INSTANCE_POOL_CLUSTER_FAILURE, SKIPPED_SLOW_NODES, ATTACH_PROJECT_FAILURE, UPDATE_INSTANCE_PROFILE_FAILURE, DATABASE_CONNECTION_FAILURE, REQUEST_THROTTLED, SELF_BOOTSTRAP_FAILURE, GLOBAL_INIT_SCRIPT_FAILURE, SLOW_IMAGE_DOWNLOAD, INVALID_SPARK_IMAGE, NPIP_TUNNEL_TOKEN_FAILURE, HIVE_METASTORE_PROVISIONING_FAILURE, AZURE_INVALID_DEPLOYMENT_TEMPLATE, AZURE_UNEXPECTED_DEPLOYMENT_TEMPLATE_FAILURE, SUBNET_EXHAUSTED_FAILURE, BOOTSTRAP_TIMEOUT, STORAGE_DOWNLOAD_FAILURE, CONTROL_PLANE_REQUEST_FAILURE, BOOTSTRAP_TIMEOUT_CLOUD_PROVIDER_EXCEPTION, AWS_INSUFFICIENT_INSTANCE_CAPACITY_FAILURE, DOCKER_IMAGE_PULL_FAILURE, AZURE_VNET_CONFIGURATION_FAILURE, NPIP_TUNNEL_SETUP_FAILURE, AWS_AUTHORIZATION_FAILURE, NEPHOS_RESOURCE_MANAGEMENT, STS_CLIENT_SETUP_FAILURE, SECURITY_DAEMON_REGISTRATION_EXCEPTION, AWS_REQUEST_LIMIT_EXCEEDED, AWS_INSUFFICIENT_FREE_ADDRESSES_IN_SUBNET_FAILURE, AWS_UNSUPPORTED_FAILURE, AZURE_QUOTA_EXCEEDED_EXCEPTION, AZURE_OPERATION_NOT_ALLOWED_EXCEPTION, NFS_MOUNT_FAILURE, K8S_AUTOSCALING_FAILURE, K8S_DBR_CLUSTER_LAUNCH_TIMEOUT, SPARK_IMAGE_DOWNLOAD_FAILURE, AZURE_VM_EXTENSION_FAILURE, WORKSPACE_CANCELLED_ERROR, AWS_MAX_SPOT_INSTANCE_COUNT_EXCEEDED_FAILURE, TEMPORARILY_UNAVAILABLE, WORKER_SETUP_FAILURE, IP_EXHAUSTION_FAILURE, GCP_QUOTA_EXCEEDED, CLOUD_PROVIDER_RESOURCE_STOCKOUT, GCP_SERVICE_ACCOUNT_DELETED, AZURE_BYOK_KEY_PERMISSION_FAILURE, SPOT_INSTANCE_TERMINATION, AZURE_EPHEMERAL_DISK_FAILURE, ABUSE_DETECTED, IMAGE_PULL_PERMISSION_DENIED, WORKSPACE_CONFIGURATION_ERROR, SECRET_RESOLUTION_ERROR, UNSUPPORTED_INSTANCE_TYPE, CLOUD_PROVIDER_DISK_SETUP_FAILURE, SSH_BOOTSTRAP_FAILURE, AWS_INACCESSIBLE_KMS_KEY_FAILURE, INIT_CONTAINER_NOT_FINISHED, SPARK_IMAGE_DOWNLOAD_THROTTLED, SPARK_IMAGE_NOT_FOUND, CLUSTER_OPERATION_THROTTLED, CLUSTER_OPERATION_TIMEOUT, SERVERLESS_LONG_RUNNING_TERMINATED, AZURE_PACKED_DEPLOYMENT_PARTIAL_FAILURE, INVALID_WORKER_IMAGE_FAILURE, WORKSPACE_UPDATE, INVALID_AWS_PARAMETER, DRIVER_OUT_OF_DISK, DRIVER_OUT_OF_MEMORY, DRIVER_LAUNCH_TIMEOUT, DRIVER_UNEXPECTED_FAILURE, UNEXPECTED_POD_RECREATION, GCP_INACCESSIBLE_KMS_KEY_FAILURE, GCP_KMS_KEY_PERMISSION_DENIED, DRIVER_EVICTION, USER_INITIATED_VM_TERMINATION, GCP_IAM_TIMEOUT, AWS_RESOURCE_QUOTA_EXCEEDED, CLOUD_ACCOUNT_SETUP_FAILURE, AWS_INVALID_KEY_PAIR, DRIVER_POD_CREATION_FAILURE, MAINTENANCE_MODE, INTERNAL_CAPACITY_FAILURE, EXECUTOR_POD_UNSCHEDULED, STORAGE_DOWNLOAD_FAILURE_SLOW, STORAGE_DOWNLOAD_FAILURE_THROTTLED, DYNAMIC_SPARK_CONF_SIZE_EXCEEDED, AWS_INSTANCE_PROFILE_UPDATE_FAILURE, INSTANCE_POOL_NOT_FOUND, INSTANCE_POOL_MAX_CAPACITY_REACHED, AWS_INVALID_KMS_KEY_STATE, GCP_INSUFFICIENT_CAPACITY, GCP_API_RATE_QUOTA_EXCEEDED, GCP_RESOURCE_QUOTA_EXCEEDED, GCP_IP_SPACE_EXHAUSTED, GCP_SERVICE_ACCOUNT_ACCESS_DENIED, GCP_SERVICE_ACCOUNT_NOT_FOUND, GCP_FORBIDDEN, GCP_NOT_FOUND, RESOURCE_USAGE_BLOCKED, DATA_ACCESS_CONFIG_CHANGED, ACCESS_TOKEN_FAILURE, INVALID_INSTANCE_PLACEMENT_PROTOCOL, BUDGET_POLICY_RESOLUTION_FAILURE, IN_PENALTY_BOX, DISASTER_RECOVERY_REPLICATION, BOOTSTRAP_TIMEOUT_DUE_TO_MISCONFIG, INSTANCE_UNREACHABLE_DUE_TO_MISCONFIG, STORAGE_DOWNLOAD_FAILURE_DUE_TO_MISCONFIG, CONTROL_PLANE_REQUEST_FAILURE_DUE_TO_MISCONFIG, CLOUD_PROVIDER_LAUNCH_FAILURE_DUE_TO_MISCONFIG, GCP_SUBNET_NOT_READY, CLOUD_OPERATION_CANCELLED, CLOUD_PROVIDER_INSTANCE_NOT_LAUNCHED, GCP_TRUSTED_IMAGE_PROJECTS_VIOLATED, BUDGET_POLICY_LIMIT_ENFORCEMENT_ACTIVATED, EOS_SPARK_IMAGE, NO_MATCHED_K8S, LAZY_ALLOCATION_TIMEOUT, DRIVER_NODE_UNREACHABLE, SECRET_CREATION_FAILURE, POD_SCHEDULING_FAILURE, POD_ASSIGNMENT_FAILURE, ALLOCATION_TIMEOUT, ALLOCATION_TIMEOUT_NO_UNALLOCATED_CLUSTERS, ALLOCATION_TIMEOUT_NO_MATCHED_CLUSTERS, ALLOCATION_TIMEOUT_NO_READY_CLUSTERS, ALLOCATION_TIMEOUT_NO_WARMED_UP_CLUSTERS, ALLOCATION_TIMEOUT_NODE_DAEMON_NOT_READY, ALLOCATION_TIMEOUT_NO_HEALTHY_CLUSTERS, NETVISOR_SETUP_TIMEOUT, NO_MATCHED_K8S_TESTING_TAG, CLOUD_PROVIDER_RESOURCE_STOCKOUT_DUE_TO_MISCONFIG, GKE_BASED_CLUSTER_TERMINATION, ALLOCATION_TIMEOUT_NO_HEALTHY_AND_WARMED_UP_CLUSTERS, DOCKER_INVALID_OS_EXCEPTION, DOCKER_CONTAINER_CREATION_EXCEPTION, DOCKER_IMAGE_TOO_LARGE_FOR_INSTANCE_EXCEPTION, DNS_RESOLUTION_ERROR, GCP_DENIED_BY_ORG_POLICY, SECRET_PERMISSION_DENIED, NETWORK_CHECK_NIC_FAILURE, NETWORK_CHECK_DNS_SERVER_FAILURE, NETWORK_CHECK_STORAGE_FAILURE, NETWORK_CHECK_METADATA_ENDPOINT_FAILURE, NETWORK_CHECK_CONTROL_PLANE_FAILURE, NETWORK_CHECK_MULTIPLE_COMPONENTS_FAILURE, DRIVER_UNHEALTHY, USAGE_POLICY_ENTITLEMENT_DENIED, K8S_ACTIVE_POD_QUOTA_EXCEEDED, CLOUD_ACCOUNT_POD_QUOTA_EXCEEDED, NETWORK_CHECK_NIC_FAILURE_DUE_TO_MISCONFIG, NETWORK_CHECK_DNS_SERVER_FAILURE_DUE_TO_MISCONFIG, NETWORK_CHECK_STORAGE_FAILURE_DUE_TO_MISCONFIG, NETWORK_CHECK_METADATA_ENDPOINT_FAILURE_DUE_TO_MISCONFIG, NETWORK_CHECK_CONTROL_PLANE_FAILURE_DUE_TO_MISCONFIG, NETWORK_CHECK_MULTIPLE_COMPONENTS_FAILURE_DUE_TO_MISCONFIG, DBR_IMAGE_RESOLUTION_FAILURE, CONTROL_PLANE_CONNECTION_FAILURE, CONTROL_PLANE_CONNECTION_FAILURE_DUE_TO_MISCONFIG, RATE_LIMITED, MTLS_PORT_CONNECTIVITY_FAILURE, HIVEMETASTORE_CONNECTIVITY_FAILURE

typestring

type of the termination

Values: SUCCESS, CLIENT_ERROR, SERVICE_FAULT, CLOUD_FAILURE

parametersobject

list of parameters that provide additional information about why the cluster was terminated

summarystring

A short summary of the health status in case of degraded/failed warehouses.

detailsstring

Details about errors that are causing current degraded/failed status.

List GA

GET /api/2.0/sql/warehouses

Lists all SQL warehouses that a user has access to.

API scopes: sql

Parameters

run_as_user_idint64query

Deprecated: this field is ignored by the server. Service Principal which will be used to fetch the list of endpoints. If not specified, SQL Gateway will use the user from the session header.

page_sizeint32query

The max number of warehouses to return.

page_tokenstringquery

A page token, received from a previous ListWarehouses call. Provide this to retrieve the subsequent page; otherwise the first will be retrieved.

When paginating, all other parameters provided to ListWarehouses must match the call that provided the page token.

Response

Returns a list of EndpointInfo objects.

Create GA

POST /api/2.0/sql/warehouses

Creates a new SQL warehouse.

API scopes: sql

Request body

namestring

Logical name for the cluster.

Supported values:

  • Must be unique within an org.
  • Must be less than 100 characters.
cluster_sizestring

Size of the clusters allocated for this warehouse. Increasing the size of a spark cluster allows you to run larger queries on it. If you want to increase the number of concurrent queries, please tune max_num_clusters.

Supported values:

  • 2X-Small
  • X-Small
  • Small
  • Medium
  • Large
  • X-Large
  • 2X-Large
  • 3X-Large
  • 4X-Large
  • 5X-Large
min_num_clustersint32

Minimum number of available clusters that will be maintained for this SQL warehouse. Increasing this will ensure that a larger number of clusters are always running and therefore may reduce the cold start time for new queries. This is similar to reserved vs. revocable cores in a resource manager.

Supported values:

  • Must be > 0
  • Must be <= min(max_num_clusters, 30)

Defaults to 1

Default: 1

max_num_clustersint32

Maximum number of clusters that the autoscaler will create to handle concurrent queries.

Supported values:

  • Must be >= min_num_clusters
  • Must be <= 40.

Defaults to min_clusters if unset.

auto_stop_minsint32

The amount of time in minutes that a SQL warehouse must be idle (i.e., no RUNNING queries) before it is automatically stopped.

Supported values:

  • Must be == 0 or >= 10 mins
  • 0 indicates no autostop.

Defaults to 120 mins

Default: 120

creator_namestring

warehouse creator name

instance_profile_arnstring

Deprecated. Instance profile used to pass IAM role to the cluster

tagsobject

A set of key-value pairs that will be tagged on all resources (e.g., AWS instances and EBS volumes) associated with this SQL warehouse.

Supported values:

  • Number of tags < 45.
Show child attributesHide child attributes
custom_tagsarray of object
Show child attributesHide child attributes
keystring
valuestring
spot_instance_policystring

Configurations whether the endpoint should use spot instances.

Default: COST_OPTIMIZED

Values: POLICY_UNSPECIFIED, COST_OPTIMIZED, RELIABILITY_OPTIMIZED

enable_photonboolean

Configures whether the warehouse should use Photon optimized clusters.

Defaults to true.

channelobject

Channel Details

Show child attributesHide child attributes
namestring

Values: CHANNEL_NAME_UNSPECIFIED, CHANNEL_NAME_PREVIEW, CHANNEL_NAME_CURRENT, CHANNEL_NAME_PREVIOUS, CHANNEL_NAME_CUSTOM

dbsql_versionstring
enable_serverless_computeboolean

Configures whether the warehouse should use serverless compute

warehouse_typestring

Warehouse type: PRO or CLASSIC. If you want to use serverless compute, you must set to PRO and also set the field enable_serverless_compute to true.

Values: TYPE_UNSPECIFIED, CLASSIC, PRO

Response

idstring

Id for the SQL warehouse. This value is unique across all SQL warehouses.

Update GA

POST /api/2.0/sql/warehouses/{id}/edit

Updates the configuration for a SQL warehouse.

API scopes: sql

Parameters

idstringpath

Required. Id of the warehouse to configure.

Request body

namestring

Logical name for the cluster.

Supported values:

  • Must be unique within an org.
  • Must be less than 100 characters.
cluster_sizestring

Size of the clusters allocated for this warehouse. Increasing the size of a spark cluster allows you to run larger queries on it. If you want to increase the number of concurrent queries, please tune max_num_clusters.

Supported values:

  • 2X-Small
  • X-Small
  • Small
  • Medium
  • Large
  • X-Large
  • 2X-Large
  • 3X-Large
  • 4X-Large
  • 5X-Large
min_num_clustersint32

Minimum number of available clusters that will be maintained for this SQL warehouse. Increasing this will ensure that a larger number of clusters are always running and therefore may reduce the cold start time for new queries. This is similar to reserved vs. revocable cores in a resource manager.

Supported values:

  • Must be > 0
  • Must be <= min(max_num_clusters, 30)

Defaults to 1

Default: 1

max_num_clustersint32

Maximum number of clusters that the autoscaler will create to handle concurrent queries.

Supported values:

  • Must be >= min_num_clusters
  • Must be <= 40.

Defaults to min_clusters if unset.

auto_stop_minsint32

The amount of time in minutes that a SQL warehouse must be idle (i.e., no RUNNING queries) before it is automatically stopped.

Supported values:

  • Must be == 0 or >= 10 mins
  • 0 indicates no autostop.

Defaults to 120 mins

Default: 120

creator_namestring

warehouse creator name

instance_profile_arnstring

Deprecated. Instance profile used to pass IAM role to the cluster

tagsobject

A set of key-value pairs that will be tagged on all resources (e.g., AWS instances and EBS volumes) associated with this SQL warehouse.

Supported values:

  • Number of tags < 45.
Show child attributesHide child attributes
custom_tagsarray of object
Show child attributesHide child attributes
keystring
valuestring
spot_instance_policystring

Configurations whether the endpoint should use spot instances.

Default: COST_OPTIMIZED

Values: POLICY_UNSPECIFIED, COST_OPTIMIZED, RELIABILITY_OPTIMIZED

enable_photonboolean

Configures whether the warehouse should use Photon optimized clusters.

Defaults to true.

channelobject

Channel Details

Show child attributesHide child attributes
namestring

Values: CHANNEL_NAME_UNSPECIFIED, CHANNEL_NAME_PREVIEW, CHANNEL_NAME_CURRENT, CHANNEL_NAME_PREVIOUS, CHANNEL_NAME_CUSTOM

dbsql_versionstring
enable_serverless_computeboolean

Configures whether the warehouse should use serverless compute

warehouse_typestring

Warehouse type: PRO or CLASSIC. If you want to use serverless compute, you must set to PRO and also set the field enable_serverless_compute to true.

Values: TYPE_UNSPECIFIED, CLASSIC, PRO

Delete GA

DELETE /api/2.0/sql/warehouses/{id}

Deletes a SQL warehouse.

API scopes: sql

Parameters

idstringpath

Required. Id of the SQL warehouse.

Get Workspace Warehouse Config GA

GET /api/2.0/sql/config/warehouses

Gets the workspace level configuration that is shared by all SQL warehouses in a workspace.

API scopes: sql

Response

security_policystring

Security policy for warehouses

Values: NONE, DATA_ACCESS_CONTROL, PASSTHROUGH

data_access_configarray of object

Spark confs for external hive metastore configuration JSON serialized size must be less than <= 512K

Show child attributesHide child attributes
keystring
valuestring
instance_profile_arnstring

AWS Only: The instance profile used to pass an IAM role to the SQL warehouses. This configuration is also applied to the workspace's serverless compute for notebooks and jobs.

channelobject

Optional: Channel selection details

Show child attributesHide child attributes
namestring

Values: CHANNEL_NAME_UNSPECIFIED, CHANNEL_NAME_PREVIEW, CHANNEL_NAME_CURRENT, CHANNEL_NAME_PREVIOUS, CHANNEL_NAME_CUSTOM

dbsql_versionstring
enable_serverless_computeboolean

Deprecated: only setting this to true is allowed.

global_paramobject

Deprecated: Use sql_configuration_parameters

Show child attributesHide child attributes
config_pairarray of object

Deprecated: Use configuration_pairs

Show child attributesHide child attributes
keystring
valuestring
configuration_pairsarray of object
Show child attributesHide child attributes
keystring
valuestring
config_paramobject

Deprecated: Use sql_configuration_parameters

Show child attributesHide child attributes
config_pairarray of object

Deprecated: Use configuration_pairs

Show child attributesHide child attributes
keystring
valuestring
configuration_pairsarray of object
Show child attributesHide child attributes
keystring
valuestring
sql_configuration_parametersobject

SQL configuration parameters

Show child attributesHide child attributes
config_pairarray of object

Deprecated: Use configuration_pairs

Show child attributesHide child attributes
keystring
valuestring
configuration_pairsarray of object
Show child attributesHide child attributes
keystring
valuestring
google_service_accountstring

GCP only: Google Service Account used to pass to cluster to access Google Cloud Storage

enabled_warehouse_typesarray of object

List of Warehouse Types allowed in this workspace (limits allowed value of the type field in CreateWarehouse and EditWarehouse). Note: Some types cannot be disabled, they don't need to be specified in SetWorkspaceWarehouseConfig. Note: Disabling a type may cause existing warehouses to be converted to another type. Used by frontend to save specific type availability in the warehouse create and edit form UI.

Show child attributesHide child attributes
warehouse_typestring

Values: TYPE_UNSPECIFIED, CLASSIC, PRO

enabledboolean

If set to false the specific warehouse type will not be allowed as a value for warehouse_type in CreateWarehouse and EditWarehouse

Set Workspace Warehouse Config GA

PUT /api/2.0/sql/config/warehouses

Sets the workspace level configuration that is shared by all SQL warehouses in a workspace.

API scopes: sql

Request body

security_policystring

Security policy for warehouses

Values: NONE, DATA_ACCESS_CONTROL, PASSTHROUGH

data_access_configarray of object

Spark confs for external hive metastore configuration JSON serialized size must be less than <= 512K

Show child attributesHide child attributes
keystring
valuestring
instance_profile_arnstring

AWS Only: The instance profile used to pass an IAM role to the SQL warehouses. This configuration is also applied to the workspace's serverless compute for notebooks and jobs.

channelobject

Optional: Channel selection details

Show child attributesHide child attributes
namestring

Values: CHANNEL_NAME_UNSPECIFIED, CHANNEL_NAME_PREVIEW, CHANNEL_NAME_CURRENT, CHANNEL_NAME_PREVIOUS, CHANNEL_NAME_CUSTOM

dbsql_versionstring
enable_serverless_computeboolean

Deprecated: only setting this to true is allowed.

global_paramobject

Deprecated: Use sql_configuration_parameters

Show child attributesHide child attributes
config_pairarray of object

Deprecated: Use configuration_pairs

Show child attributesHide child attributes
keystring
valuestring
configuration_pairsarray of object
Show child attributesHide child attributes
keystring
valuestring
config_paramobject

Deprecated: Use sql_configuration_parameters

Show child attributesHide child attributes
config_pairarray of object

Deprecated: Use configuration_pairs

Show child attributesHide child attributes
keystring
valuestring
configuration_pairsarray of object
Show child attributesHide child attributes
keystring
valuestring
sql_configuration_parametersobject

SQL configuration parameters

Show child attributesHide child attributes
config_pairarray of object

Deprecated: Use configuration_pairs

Show child attributesHide child attributes
keystring
valuestring
configuration_pairsarray of object
Show child attributesHide child attributes
keystring
valuestring
google_service_accountstring

GCP only: Google Service Account used to pass to cluster to access Google Cloud Storage

enabled_warehouse_typesarray of object

List of Warehouse Types allowed in this workspace (limits allowed value of the type field in CreateWarehouse and EditWarehouse). Note: Some types cannot be disabled, they don't need to be specified in SetWorkspaceWarehouseConfig. Note: Disabling a type may cause existing warehouses to be converted to another type. Used by frontend to save specific type availability in the warehouse create and edit form UI.

Show child attributesHide child attributes
warehouse_typestring

Values: TYPE_UNSPECIFIED, CLASSIC, PRO

enabledboolean

If set to false the specific warehouse type will not be allowed as a value for warehouse_type in CreateWarehouse and EditWarehouse

Start Warehouse GA

POST /api/2.0/sql/warehouses/{id}/start

Starts a SQL warehouse.

API scopes: sql

Parameters

idstringpath

Required. Id of the SQL warehouse.

Stop Warehouse GA

POST /api/2.0/sql/warehouses/{id}/stop

Stops a SQL warehouse.

API scopes: sql

Parameters

idstringpath

Required. Id of the SQL warehouse.