database-migrations

Solid

Database migration best practices for schema changes, data migrations, rollbacks, and zero-downtime deployments across PostgreSQL, MySQL, and common ORMs (Prisma, Drizzle, Kysely, Django, TypeORM, golang-migrate).

API & Backend 22 stars 5 forks Updated 6 days ago MIT

Install

View on GitHub

Quality Score: 84/100

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

Skill Content

# /supergraph:database-migrations Safe, reversible database schema changes for production systems. Announce: "๐Ÿ—„๏ธ /supergraph:database-migrations โ€” checking blast radius and migration safety..." ## When to Activate - Creating or altering database tables - Adding/removing columns or indexes - Running data migrations (backfill, transform) - Planning zero-downtime schema changes - Setting up migration tooling for a new project ## Steps ### 1. Check blast radius (MANDATORY before writing any migration) Use `CBM_PROJECT`: `search_graph` schema/model symbols, `trace_path` inbound and data-flow, then validated `dependencies`, `hubs`, and `test-gaps` recipes. Schema changes to hub tables (e.g. `users`, `orders`) ripple through repositories, queries, services. If blast radius > 20 files โ†’ STOP and discuss with user. **Serena symbol-level impact (optional):** ``` mcp__serena__find_referencing_symbols(symbol=<column_or_model_name>) ``` Finds ORM field references that graph tools see only at file level โ€” e.g. a Prisma field rename that `query_graph` sees as "file touched" but Serena sees as "12 usages in service layer". Skip if Serena unavailable. ### 2. Choose migration pattern Select the appropriate pattern from the sections below (PostgreSQL, Prisma, Drizzle, etc.) based on detected project type from `.supergraph-env`. ### 3. Write migration Follow Migration Safety Checklist before writing SQL/ORM migration code. ### 4. Verify flows After migration written: Use `trace_path(p...

Details

Author
datit309
Repository
datit309/supergraph
Created
4 months ago
Last Updated
6 days ago
Language
Shell
License
MIT

Integrates with

Similar Skills

Semantically similar based on skill content โ€” not just same category