migrate-validate
Validate pending migrations for foreign key consistency, rollback safety, and best practices
Works with
--- name: migrate-validate description: Validate pending migrations for foreign key consistency, rollback safety, and best practices license: MIT --- # Migrate Validate Validate all pending database migrations for correctness, safety, and adherence to best practices. ## When to use Before applying migrations to catch issues early -- foreign key references to non-existent tables, missing rollback SQL, destructive operations without safeguards, and naming convention violations. ## Steps 1. **Find pending migrations** -- use `Glob` to list all migration files, cross-reference with applied history via `mcp__plugin_ruflo-core_ruflo__memory_search --namespace migrations` (or `memory_list`) to identify pending ones. The `memory_*` tool family routes by namespace; `agentdb_hierarchical-*` does NOT (it routes by tier), so use `memory_*` here. 2. **Parse SQL** -- use `Read` to load each pending `.up.sql` and `.down.sql` file and parse the SQL statements 3. **Check foreign keys** -- verify that all REFERENCES targets exist in the current schema or in prior migrations (both applied and pending) 4. **Check NOT NULL defaults** -- verify that any ADD COLUMN with NOT NULL has a DEFAULT value 5. **Check rollback completeness** -- verify every CREATE/ALTER in the UP file has a corresponding DROP/ALTER in the DOWN file 6. **Flag destructive ops** -- warn on DROP TABLE, DROP COLUMN, TRUNCATE without explicit confirmation 7. **Check idempotency** -- verify IF EXISTS / IF NOT EXISTS is used for safety 8. **Check naming** -- verify table names are plural, column names are snake_case, index names follow `idx_table_column` convention 9. **Store validation patterns** -- two paths (per ruflo-cost-tracker ADR-0001 dual-path pattern): - **Pattern store (typed, recommended)**: `mcp__plugin_ruflo-core_ruflo__agentdb_pattern-store` with `type: 'migration-validation'`. No namespace arg — ReasoningBank routes it. - **Plain store (namespace-routable)**: `mcp__plugin_ruflo-core_ruflo__memory_store --namespace migrations` for validation results tied to a specific migration number. 10. **Report** -- display: errors (must fix), warnings (should fix), info (suggestions), with file path and line number for each issue ## CLI alternative ```bash npx @claude-flow/cli@latest memory search --query "migration validation results" --namespace migrations ```
More Deployment & CI/CD skills
azure-enterprise-infra-planner
microsoft/azure-skills
Architect and provision enterprise Azure infrastructure from workload descriptions. For cloud architects and platform engineers planning networking, identity, security, compliance, and multi-resource topologies with WAF alignment. Generates Bicep or Terraform directly (no azd). WHEN: 'plan Azure infrastructure', 'architect Azure landing zone', 'design hub-spoke network', 'plan multi-region DR topology', 'set up VNets firewalls and private endpoints', 'subscription-scope Bicep deployment', 'Azure Backup for VM workloads'. PREFER azure-prepare FOR app-centric workflows.
azure-kubernetes-app-deploy
microsoft/azure-skills
Use when deploying an existing web application or API to an already-running Azure Kubernetes Service cluster. Detects the framework, generates a Dockerfile and Kubernetes manifests, validates against AKS Deployment Safeguards, and deploys with verification. WHEN: deploy app to AKS, deploy to existing AKS cluster, containerize app for Kubernetes, generate K8s manifests for Azure, set up CI/CD for AKS, my AKS deployment is failing safeguard checks, I have a Django/Express/Spring Boot app to run on AKS. DO NOT USE FOR: creating or provisioning an AKS cluster (use azure-kubernetes), assessing migration to AKS Automatic (use azure-kubernetes-automatic-readiness), or deploying to non-AKS targets like Web Apps, Container Apps, or Functions.
finetuning
microsoft/azure-skills
Fine-tune models on Microsoft Foundry using SFT (supervised), DPO (preference), or RFT (reinforcement with graders). Covers dataset preparation, training job submission, deployment, and evaluation. USE FOR: fine-tune, SFT, DPO, RFT, training data, grader, distillation, fine-tuned model, training job, large file upload, calibrate grader, deploy fine-tuned model, evaluate fine-tuned model. DO NOT USE FOR: general model deployment without fine-tuning (use deploy-model), agent creation (use agents), prompt optimization without training (use prompt-optimizer).

