alterWarehouseProperties

Sets or unsets properties on an existing Snowflake warehouse. Supports configuration options including size, type, auto-scaling, query acceleration, resource management, and timeouts.

Note: This change type does not support automatic rollback or database inspection features (snapshot, diff, diff-changelog, and generate-changelog commands).

Available attributes

Attribute

Type

Description

Required

warehouseName

String

Name of the warehouse to alter

Yes

ifExists

Boolean

If true, only alters the warehouse if it exists

No

*SET and UNSET operations cannot be mixed in the same changeset. Use separate changesets.

SET properties

Attribute

Type

Description

warehouseSize

Enum

Warehouse size: XSMALL, SMALL, MEDIUM, LARGE, XLARGE, XXLARGE, XXXLARGE, X4LARGE-X6LARGE

warehouseType

String

Warehouse type: STANDARD (default), SNOWPARK-OPTIMIZED

waitForCompletion

Boolean

If true, blocks until warehouse resize completes

maxClusterCount

Integer

Maximum number of clusters (1-10) for multi-cluster warehouses

minClusterCount

Integer

Minimum number of clusters (1-10) for multi-cluster warehouses

scalingPolicy

Enum

Scaling policy for multi-cluster: STANDARD or ECONOMY

autoSuspend

String

Seconds of inactivity before auto-suspend, or NULL to disable

autoResume

Boolean

If true, warehouse automatically resumes when queried

resourceMonitor

String

Name of resource monitor to assign

resourceConstraint

String

Resource constraint (e.g., STANDARD_GEN_2, MEMORY_16X)

enableQueryAcceleration

Boolean

Enable or disable query acceleration service

queryAccelerationMaxScaleFactor

Integer

Maximum scale factor for query acceleration (0-100)

maxConcurrencyLevel

Integer

Maximum concurrent queries (1-8)

statementQueuedTimeoutInSeconds

Integer

Max seconds a query can be queued (0-43200)

statementTimeoutInSeconds

Integer

Max seconds a query can run (0-604800)

comment

String

Comment describing the warehouse

UNSET properties

Attribute

Type

Description

unsetWarehouseType

Boolean

Unset warehouse type

unsetScalingPolicy

Boolean

Unset scaling policy

unsetMaxClusterCount

Boolean

Unset maximum cluster count

unsetMinClusterCount

Boolean

Unset minimum cluster count

unsetAutoSuspend

Boolean

Unset auto-suspend setting

unsetAutoResume

Boolean

Unset auto-resume setting

unsetResourceMonitor

Boolean

Unset resource monitor

unsetResourceConstraint

Boolean

Unset resource constraint

unsetEnableQueryAcceleration

Boolean

Unset query acceleration setting

unsetQueryAccelerationMaxScaleFactor

Boolean

Unset query acceleration max scale factor

unsetMaxConcurrencyLevel

Boolean

Unset max concurrency level

unsetStatementQueuedTimeoutInSeconds

Boolean

Unset statement queued timeout

unsetStatementTimeoutInSeconds

Boolean

Unset statement timeout

unsetComment

Boolean

Unset comment

*warehouseSize cannot be unset - warehouse must always have a size.

<?xml version="1.0" encoding="UTF-8"?>
<databaseChangeLog
  xmlns="http://www.liquibase.org/xml/ns/dbchangelog"
  xmlns:pro-snowflake="http://www.liquibase.org/xml/ns/pro-snowflake"
  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xsi:schemaLocation="http://www.liquibase.org/xml/ns/dbchangelog
        http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-latest.xsd
        http://www.liquibase.org/xml/ns/pro-snowflake
        http://www.liquibase.org/xml/ns/pro-snowflake/liquibase-pro-snowflake-latest.xsd">
  <!-- Set properties -->
  <changeSet id="set-properties" author="examples">
    <pro-snowflake:alterWarehouseProperties
            warehouseName="COMPUTE_WH"
            ifExists="true"
            warehouseSize="LARGE"
            warehouseType="STANDARD"
            maxClusterCount="5"
            minClusterCount="1"
            scalingPolicy="ECONOMY"
            autoSuspend="600"
            autoResume="true"
            resourceMonitor="MONTHLY_QUOTA"
            resourceConstraint="STANDARD_GEN_2"
            enableQueryAcceleration="true"
            queryAccelerationMaxScaleFactor="8"
            maxConcurrencyLevel="8"
            statementQueuedTimeoutInSeconds="300"
            statementTimeoutInSeconds="3600"
            comment="Production warehouse"/>
  </changeSet>
  <!-- Unset properties -->
  <changeSet id="unset-properties" author="examples">
    <pro-snowflake:alterWarehouseProperties
            warehouseName="COMPUTE_WH"
            ifExists="true"
            unsetMaxClusterCount="true"
            unsetMinClusterCount="true"
            unsetAutoSuspend="true"
            unsetAutoResume="true"
            unsetResourceMonitor="true"
            unsetResourceConstraint="true"
            unsetEnableQueryAcceleration="true"
            unsetQueryAccelerationMaxScaleFactor="true"
            unsetMaxConcurrencyLevel="true"
            unsetStatementQueuedTimeoutInSeconds="true"
            unsetStatementTimeoutInSeconds="true"
            unsetComment="true"/>
  </changeSet>
</databaseChangeLog>