A virtual warehouse is a cluster of computing resources in ByteHouse that we can scale out on demand. A virtual warehouse provides the required resources, such as CPU, memory, and temporary storage, to perform the following operations:
Executing SQL statements that require computing resources (e.g. retrieving rows from tables and views) for short and long-running queries.
Performing DML operations, such as:
Updating rows in tables (DELETE, INSERT, UPDATE)
Loading data into tables
Unloading data from tables
Virtual warehouses have the following advantages:
Read-write separation and resource separation: Separate virtual warehouses can be created to perform data loading tasks, or run queries in real time. Virtual warehouses also allow different departments or business lines to have a clear separation of resources, avoiding impact on the performance of different queries.
One-click scaling: Virtual warehouses can easily scale up or down according to business requirements for cost-effective resource utilisation.
Access control: We can also grant virtual warehouses different permissions depending on the applied role. This can provide granular access control for data.
Virtual warehouse sizes
XS (Extra small)
XL (Extra large)
Managing virtual warehouses
ByteHouse virtual warehouse page provides an interface for creating, starting, and suspending a virtual warehouse on-demand, as well as configuring and scaling up/down its computing resources.
Creating a virtual warehouse
On the virtual warehouse page, click the +New button in the upper right corner
Create Virtual Warehouse dialog will open, with which we can specify the virtual warehouse attributes to allocate computing resources.
Once done, click OK and the virtual warehouse will be created and started.
Note: ByteHouse virtual warehouses have auto-suspend/resume enabled by default.
If auto-suspend is enabled, the virtual warehouse will shut down if there is no computing request for a certain time interval.
If auto-resume is enabled, the paused virtual warehouse will wake up and resume computing when a new query is submitted. Please note that on resumption, a longer time is needed for the first query to run.
Updating a virtual warehouse
Virtual warehouse configurations can be updated at any time, with several limitations:
Only the size, auto-suspend, auto-resume, and description can be updated.
If the change results in the virtual warehouse being suspended, this may cause running queries to be interrupted.
Changes to virtual warehouse sizes will only take effect after the virtual warehouse resumes functionality from a suspended state.
Resuming a virtual warehouse
We can resume a suspended virtual warehouse by:
- Resume one or multiple virtual warehouses by selecting the items and clicking the ▷ button.
- Resume a particular virtual warehouse using the triple-dot menu and choosing Resume.
- After enabling auto-resume, users can directly choose virtual warehouse from SQL worksheet, then turn it on by executing a query.
Suspending a virtual warehouse
A virtual warehouse can be suspended by:
- Suspend one or multiple virtual warehouses by selecting the items and clicking ⏸️ button.
- Suspend a particular virtual warehouses using triple-dot menu and choosing Stop.
- After enabling auto-suspend, if there is no computing request for a certain time interval, the virtual warehouse will be auto-suspended. Currently, we support the following intervals:
- 5 minutes
- 30 minutes
- 1 hour
- 6 hours
Suspending a virtual warehouse can cause any queries that run within this warehouse to fail instantly. Be careful when performing this operation.
Dropping (deleting) a virtual warehouse
Dropping a virtual warehouse effectively suspends all the running queries. It removes the cluster from deployment and the virtual warehouse from the list of available virtual warehouses.
Updated 3 months ago