deprecation-and-migration

Plans deprecation and incremental migration of legacy systems, APIs, and database schemas.

1|Updated Sep 4, 2026
One-click install
npx skills add https://github.com/SanHsien/agent-skills --skill deprecation-and-migration-sanhsien
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: deprecation-and-migration
Source: https://github.com/SanHsien/agent-skills/tree/main/skills/deprecation-and-migration
Command: npx skills add https://github.com/SanHsien/agent-skills --skill deprecation-and-migration-sanhsien

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Removing old systems, APIs, and features is hard because consumers depend on undocumented behaviors, and rushed removals or in-place schema changes cause outages. This Skill provides a disciplined process for deciding what to deprecate, migrating consumers safely, and executing zero-downtime database schema changes. ## Core Features & Use Cases - Deprecation Decision Framework: Evaluate whether a system still earns its maintenance cost, quantify consumer impact, and choose between advisory and compulsory deprecation. - Migration Patterns: Apply the Strangler pattern, Adapter pattern, and feature-flag cutovers to move consumers incrementally from old to new implementations. - Expand/Contract Schema Migrations: Rename or drop database columns without downtime using additive phases, dual-writes, batched backfills, and tested down migrations. - Use Case: When renaming a name column to full_name in production, follow the expand → dual-write → backfill → switch reads → contract sequence so old and new code both work at every deploy step. ## Quick Start Ask the agent to plan a safe migration for renaming a production database column or deprecating a legacy API, including rollback steps for each phase.

Frequently Asked Questions about deprecation-and-migration

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I rename a database column without downtime?

Use the expand/contract pattern: add the new column as nullable, dual-write both columns, backfill existing rows in batches, switch reads to the new column, then drop the old column in a separate later deploy. Never rename in place, since old and new code run simultaneously during rollout.

How do I deprecate an API or legacy system safely?

First build a production-proven replacement, then announce deprecation with a migration guide and tooling. Migrate consumers incrementally, verify zero active usage through metrics and logs, and only then remove the old code, tests, and documentation.

What is the difference between advisory and compulsory deprecation?

Advisory deprecation uses warnings and documentation while users migrate on their own timeline, suitable when the old system is stable. Compulsory deprecation sets a hard removal deadline and is reserved for security risks or unsustainable maintenance costs, and requires providing migration tooling and support.

When should I use the Strangler pattern for migration?

Use the Strangler pattern when replacing a system that serves live traffic. Run old and new systems in parallel, route traffic incrementally from old to new starting with a small canary percentage, and remove the old system once it handles zero traffic.

Why do database migrations fail during deployment rollouts?

Failures happen when a schema change ships in the same deploy as the code depending on it, so during the rollout window one version queries a column that does not exist. The fix is additive phases where old and new code are both valid against the schema at every step.

What are the limitations of keeping unused code just in case?

Unused code still incurs maintenance cost through tests, dependency updates, security patches, and onboarding overhead. If functionality is needed later it can be rebuilt, and keeping it typically costs more than rebuilding, so it should be deprecated with a concrete plan.