snowflake-reliability-patterns

Featured

Implement Snowflake reliability patterns: replication, failover, Time Travel recovery, and application-level resilience for Snowflake integrations. Use when building fault-tolerant pipelines, configuring disaster recovery, or adding resilience to production Snowflake services. Trigger with phrases like "snowflake reliability", "snowflake failover", "snowflake replication", "snowflake disaster recovery", "snowflake Time Travel".

AI & Automation 2,926 stars 433 forks Updated yesterday MIT

Install

View on GitHub

Quality Score: 99/100

Stars 20%
100
Recency 20%
100
Frontmatter 20%
70
Documentation 15%
100
Issue Health 10%
50
License 10%
100
Description 5%
100

Skill Content

# Snowflake Reliability Patterns ## Overview Production-grade reliability patterns for Snowflake: database replication, account failover, Time Travel recovery, and application-level circuit breakers. ## Instructions ### Step 1: Time Travel for Point-in-Time Recovery ```sql -- Query historical data (up to 90 days on Enterprise Edition) SELECT * FROM orders AT (TIMESTAMP => '2026-03-21 14:00:00'::TIMESTAMP_NTZ); -- Restore a table to a previous state CREATE OR REPLACE TABLE orders CLONE orders AT (TIMESTAMP => '2026-03-21 14:00:00'::TIMESTAMP_NTZ); -- Restore a dropped table UNDROP TABLE orders; UNDROP SCHEMA my_schema; UNDROP DATABASE my_database; -- Query by offset (5 minutes ago) SELECT * FROM orders AT (OFFSET => -300); -- Query by statement ID (before a specific query ran) SELECT * FROM orders BEFORE (STATEMENT => '<query_id_of_bad_update>'); -- Set retention period per table ALTER TABLE critical_data SET DATA_RETENTION_TIME_IN_DAYS = 90; ALTER TABLE temp_staging SET DATA_RETENTION_TIME_IN_DAYS = 0; -- No Time Travel ``` ### Step 2: Database Replication Across Regions ```sql -- Enable replication on source account (primary) ALTER DATABASE PROD_DW ENABLE REPLICATION TO ACCOUNTS myorg.us_east_account, myorg.eu_west_account; -- On target account: create replica database CREATE DATABASE PROD_DW_REPLICA AS REPLICA OF myorg.us_west_account.PROD_DW; -- Refresh replica (manual or scheduled) ALTER DATABASE PROD_DW_REPLICA REFRESH; -- Check replication status...

Details

Author
jeremylongshore
Repository
jeremylongshore/claude-code-plugins-plus-skills
Created
1 years ago
Last Updated
yesterday
Language
Python
License
MIT

Integrates with

Bundled in these plugins

Similar Skills

Semantically similar based on skill content — not just same category