Syntic

Skills may execute instructions and code that could affect your environment. Marketplace scans reduce risk but do not guarantee safety. Always review files, run your own security checks, and use at your own risk.

EngineeringFree Safe

migration-architect

Security Scan Summary

Status: Safe

Source: Syntic Skills registry

Automated security scan completed with no high-risk patterns detected. Manual review is still required.

About This Skill

Use when planning a database migration, infrastructure cutover, system replacement, or any high-risk transition needing explicit rollback paths and compatibility validation.

Downloadable SKILL.md

Download SKILL.md and place it in your Syntic skills folder. For Syntic Code, install in your local skills directory, review contents, and run in a controlled environment first. Acknowledge the risk notice above to enable the download.

SKILL.md
---
name: migration-architect
description: Use when planning a database migration, infrastructure cutover, system replacement, or any high-risk transition needing explicit rollback paths and compatibility validation.
category: Engineering
version: 1.0.0
tools: []
---

# Migration Architect

Zero-downtime migration planning, compatibility validation, and rollback strategy generation for database, service, and infrastructure migrations. Combines proven migration patterns with a repeatable planning method to keep business impact minimal during complex transitions.

## Core Capabilities

**Migration strategy planning** — break complex migrations into phased steps with clear validation gates; assess risk and identify failure points before execution; estimate realistic timelines from migration complexity and resource constraints; produce stakeholder communication templates and progress tracking.

**Compatibility analysis** — analyze database schema changes for backward compatibility; detect breaking changes in REST/GraphQL APIs and microservice interfaces; identify data type mismatches and conversion needs; validate referential integrity and business-rule changes.

**Rollback strategy generation** — produce a rollback procedure for every migration phase; define point-in-time data restoration steps; plan service version rollbacks with traffic management; define success criteria and rollback triggers per checkpoint.

## Method — plan, check compatibility, generate rollback

Work the migration in three passes: (1) build the migration plan (phases, risks, estimated duration) from the spec; (2) check schema/API compatibility between the before and after states and classify each change as compatible, breaking, or potentially breaking; (3) generate a rollback runbook keyed to the plan's phases.

**Gate:** a migration is not approved until (a) compatibility analysis reports fully compatible, or every breaking/potentially-breaking item is explicitly accepted in writing by the owner, and (b) a rollback runbook exists for every phase in the plan. Re-run both checks after any schema revision.

## Migration Patterns

### Database Migrations

**Schema evolution patterns:**
- *Expand-Contract* — expand (add new columns/tables alongside the existing schema), dual-write (application writes to both old and new schema), migrate (backfill historical data), contract (remove old columns/tables after validation).
- *Parallel Schema* — run the new schema alongside the existing one, use feature flags to route traffic between schemas, validate data consistency between the parallel systems, cut over once confidence is high.
- *Event Sourcing Migration* — capture all changes as events during the migration window, apply events to the new schema for consistency, enable replay for rollback scenarios.

**Data migration strategies:**
- *Bulk Data Migration* — full snapshot copy during a maintenance window, incremental sync with change tracking, or real-time stream-processing transformation pipelines.
- *Dual-Write Pattern* — write to both source and target during migration, implement compensation for write failures, use distributed transactions where consistency is critical.
- *Change Data Capture (CDC)* — stream database changes to the target system, maintain eventual consistency during migration, enables zero-downtime migration for large datasets.

### Service Migrations

**Strangler Fig Pattern** — intercept requests through a proxy/gateway, gradually replace functionality incrementally, retire legacy components as new ones prove stable, monitor performance and error rates throughout. Route decisions typically flow: client → API gateway → legacy service/legacy DB or new service/new DB, based on a routing rule that shifts over time.

**Parallel Run Pattern** — run old and new services simultaneously, shadow production traffic to both, compare outputs to validate correctness, shift traffic percentage gradually based on confidence.

**Canary Deployment Pattern** — deploy the new service to a small percentage of users, track latency/errors/business KPIs, increase traffic percentage as confidence grows, complete rollout once validation passes.

### Infrastructure Migrations

**Cloud-to-cloud** — assess existing resources/dependencies and map to target-cloud equivalents, identify vendor-specific features needing refactor; pilot on non-critical workloads to validate performance/cost models; production migration uses infrastructure-as-code, cross-cloud networking during transition, and maintained disaster recovery.

**On-premises to cloud** — *lift-and-shift* (minimal application changes, optimize later), *re-architecture* (redesign for cloud-native patterns — microservices, containers, serverless), or a *hybrid approach* (sensitive data stays on-prem, compute moves to cloud, secure connectivity between environments).

## Feature Flags for Migrations

Use progressive rollout: a feature flag carries a rollout percentage and assigns users deterministically (hash the flag name + user ID, compare against the percentage) so the same user always lands on the same side. Increase the percentage in fixed steps (e.g. +10 at a time) toward the target, monitoring at each step.

Pair progressive rollout with a **circuit breaker**: track consecutive failures against a threshold (e.g. 5) and a timeout (e.g. 60s); once the threshold trips, open the circuit and fall back to the legacy path automatically; after the timeout, allow a single trial call (half-open) before fully closing back to the new path. This keeps migrations self-healing under load rather than requiring a human to notice and roll back manually.

## Data Validation and Reconciliation

**Validation strategies:**
- Row count validation — compare record counts source vs. target, account for soft deletes/filtered records, alert on threshold breach.
- Checksums/hashing — generate checksums for critical data subsets, compare hashes to detect drift, sample for large datasets.
- Business logic validation — run critical business queries on both systems, compare aggregates (sums, counts, averages), validate derived/calculated data.

**Reconciliation patterns:**
- Delta detection — find rows missing in target and rows extra in target via anti-join comparisons between source and target tables on primary key.
- Automated correction — idempotent repair operations for common issues, with every correction logged for audit.

## Rollback Strategies

**Database** — maintain schema version control and backward-compatible migrations where possible; keep a rollback script per migration step; use point-in-time recovery from backups, transaction-log replay for precise rollback points, and snapshots at each checkpoint.

**Service** — blue-green deployment (keep the previous version running, switch traffic back to blue on issues, maintain parallel infrastructure during the window) or rolling rollback (gradually shift traffic back, monitor health throughout, automated rollback triggers).

**Infrastructure** — version-control all infrastructure definitions, maintain rollback Terraform/CloudFormation templates and test them in staging; preserve data in its original location during migration and maintain backup strategies across both environments.

## Risk Assessment Framework

**Risk categories:** technical (data loss/corruption, downtime, integration failures, scalability under load), business (revenue impact, customer experience, compliance/regulatory, brand reputation), operational (knowledge gaps, insufficient test coverage, weak monitoring/alerting, communication breakdowns).

**Mitigations:** technical — comprehensive testing (unit, integration, load, chaos), gradual rollout with automated rollback triggers, data validation/reconciliation, performance monitoring. Business — stakeholder communication plans, business-continuity procedures, customer notification, revenue-protection measures. Operational — team training/documentation, tested runbooks, on-call rotation, post-migration review.

## Migration Runbooks

**Pre-migration:** plan reviewed and approved; rollback procedures tested; monitoring/alerting configured; team roles defined; stakeholder communication activated; backup/recovery verified; test environment validated; performance benchmarks set; security review complete; compliance verified.

**During migration:** execute phases in planned order; monitor KPIs continuously; validate data consistency at each checkpoint; communicate progress; document deviations; execute rollback if success criteria aren't met; coordinate with dependent teams; keep detailed execution logs.

**Post-migration:** validate all success criteria met; run full system health checks; execute data reconciliation; monitor performance for 72 hours; update documentation/runbooks; decommission legacy systems if applicable; run a retrospective; archive migration artifacts; update disaster-recovery procedures.

## Reporting

Deliver the migration plan (phases, risks, estimated duration), the compatibility report (overall compatibility status, breaking-change count, potentially-breaking count), and the rollback runbook directly in chat, organized by phase. If evaluating an unfamiliar system's dependencies or vendor migration paths, use web_search; @mention the relevant service or data owner before executing any destructive step (contract phase, decommission, DROP operations).

Bundle Download

Includes SKILL.md and bundled support files where provided. Risk acknowledgement is required.

Install Targets

Syntic App

  1. 1. Create a dedicated folder for this skill in your local skills library.
  2. 2. Place SKILL.md into that folder.
  3. 3. Restart Syntic and invoke this skill on matching tasks.

Syntic Code (CLI)

  1. 1. Save SKILL.md in your local Syntic Code skills directory.
  2. 2. Keep related files in the same skill folder.
  3. 3. Run in a safe environment and validate outputs.

Source

https://github.com/alirezarezvani/claude-skills/blob/main/engineering/skills/migration-architect/SKILL.md

Open Source Link
Engineering

Related Skills