One of the challenges that many Snowflake administrators face is the daily monitoring of user and resource activity in their environment. The advantages of Snowflake's consumption-based pricing model (instantly-scalable compute sizing, usage-focused scheduling, etc.) are best employed when compute and storage activity is transparent to the business. Snowflake includes an ACCOUNT_USAGE view-based schema in the out-of-the-box Snowflake database than contains all the information related to account activity. This data can, of course, be directly queried like any other data, but wouldn't it be nice to have a single view of key metrics around data storage and activity that can be monitored day to day? In other words, a Snowflake usage dashboard.
This can now be done within Snowflake via Snowsight. Snowsight is the new user interface for Snowflake, and within Snowsight is the ability to visualize data and create persistent, sharable dashboards. Additionally, all other elements of the “default” Snowflake interface (e.g. Worksheets, History, etc.) can be found within Snowsight in a simpler, cleaner format.
You can open the Snowsight interface by clicking the Snowsight icon in the upper right of the standard Snowflake console:
A menu on the Snowsight interface connects you to worksheets, databases, compute resources (I.e. Warehouses), etc. Note that there is also a spot for Dashboards.
For example, say you want to build out a dashboard which returns the number of jobs run for each database for the current month.
Create a new Worksheet by clicking on the add worksheet button in the upper right corner of the screen.
Type up the SQL
Then simply run the query for the results.
By default, the chart will display as a line graph but you can change the chart type (along with other settings) in the control panel that appears on the right side of the screen.
Once the chart is set up as you want it, add it to a new dashboard. If you select the name of the worksheet in the upper left corner, then select Move to and New dashboard, a new dashboard will be created with your new graph as a single “tile”.
Note that you can no longer edit the worksheet from the Worksheet menu; rather, each tile on a dashboard has its own edit menu (from the 3 dots in the upper right). New queries and charts can then be created from new worksheets, then added to the existing dashboard as additional tiles.
Finally, you can Share the completed dashboard with other users. Clicking the Share button in the upper right corner allows you to add individual user names and grant view capability (note that the users must have SYSADMIN rights). The dashboard will now appear in their Dashboards menu list within Snowsight.
With a usage monitoring dashboard in place and visible to key administrative users, close oversight of your Snowflake environment is easier than ever. The depth and breadth of data in ACCOUNT_USAGE (along with sample queries) can be found in the Snowflake documentation here. Just about any aspect of Snowflake account administration can be visualized and shared via a Snowsight dashboard, bringing further value from your Snowflake data cloud.