Resource Monitors and Credit Calculation
1. Resource Monitors and Credit Calculation
In this chapter we focus on a different kind of risk: cost. Snowflake's compute model is flexible and powerful, but spend can grow quickly if it's not managed. This video covers how credits work, how to calculate what a warehouse costs, and how resource monitors give you control over consumption before it becomes a problem.2. The Cost Problem
Claro's data team runs dozens of queries a day across multiple warehouses. All it takes is one analyst kicking off an expensive ad-hoc query on a Friday afternoon and leaving it running. Without spending controls in place, that's a significant unexpected bill. Resource monitors are Snowflake's answer.3. What is a Snowflake Credit?
A Snowflake credit is the unit of compute consumption. One credit equals one hour of a Standard Gen 1 X-Small warehouse running continuously -- but credit consumption depends on both the warehouse type and size. Larger warehouses consume more credits per hour in a multiplicative pattern. Credits are only consumed while a warehouse is actively running. Auto-suspend stops consumption, though keep in mind that a longer suspend interval allows data to stay cached, which can improve query performance for repeated workloads. It's a trade-off worth considering for each warehouse.4. Credit Consumption by Warehouse Size
For a Gen 1 Standard warehouse, X-Small is the baseline at one credit per hour. Small is two. Medium is four. The pattern continues with each step roughly doubling the hourly rate. Gen 2 warehouses have different rates that vary by cloud provider, and Snowflake also offers Snowpark-optimized warehouses with their own credit schedule. For current figures across all warehouse types, always refer to the Snowflake Service Consumption Table.5. Important Caveats on Billing
Two caveats worth knowing. Virtual warehouse usage is billed per second, with a one-minute minimum each time the warehouse starts -- so a query that runs for ten seconds still costs a full minute. Snowflake's cloud services layer handles authentication, query optimization, and metadata management. It consumes credits, but those credits are only charged if cloud services usage exceeds ten percent of your daily warehouse compute. Below that threshold, cloud services are effectively included.6. What is a Resource Monitor?
A resource monitor is a Snowflake object that watches credit consumption and acts when it crosses a threshold. You define a credit quota — for example five hundred credits per month — and attach the monitor to a warehouse or to the entire account. As the warehouse consumes credits, the monitor tracks progress against the quota. When consumption hits a defined percentage, the monitor takes action: a notification, a suspension, or an immediate halt.7. Resource Monitor Actions
Resource monitors support three action types. Notify sends an alert but the warehouse keeps running, useful as an early warning. Suspend stops the warehouse after the current statement completes. Suspend Immediately halts mid-execution, cancelling running queries. Multiple thresholds can be set on a single monitor. For example, a common Claro pattern: notify at seventy-five percent, suspend at ninety, suspend immediately at one hundred, giving the team a chance to react before operations are disrupted.8. Account vs Warehouse Level Monitors
Resource monitors apply at two levels. An account-level monitor tracks total credit consumption across every warehouse — a single guardrail for the overall budget. A warehouse-level monitor is scoped to one warehouse, giving each team their own credit quota independently. The two levels can coexist. Claro might have an account-level monitor as a hard ceiling, and individual warehouse-level monitors for the analytics, data engineering, and compliance teams.9. Let's practice!
Now it's your turn. You'll put resource monitors and credit calculations into practice in the exercises ahead.Create Your Free Account
or
By continuing, you accept our Terms of Use, our Privacy Policy and that your data is stored in the USA.