Repository navigation
chore(db): drop MCP Gateway tables - #8157
Conversation
Code Review SummaryStatus: No Issues Found | Recommendation: Merge Incremental review since Files Reviewed (19 files)
Previous Review Summary (commit 39a0785)Current summary above is authoritative. Previous snapshots are kept for context only. Previous review (commit 39a0785)Status: No Issues Found | Recommendation: Merge Executive SummaryVerified the MCP Gateway table drop against the schema, generated snapshot, migration, and all call sites; no dangling references, FK dependents, or behavioral regressions were found. Files Reviewed (19 files)
Notes: all 14 Reviewed by deepseek-v4.1-flash-1017 · Input: 63.6K · Output: 11.9K · Cached: 1.2M Review guidance: REVIEW.md from base branch |
39a0785 to
d758ff4
Compare
Summary
Stacked on #8156. Drops the MCP Gateway database objects now that no code reads them.
mcp_gateway_*tables, including configs, secrets, routes, instances, provider/OAuth grants, authorization requests/codes, refresh tokens, clients, assignments, rate-limit windows, and audit events.organization.mcp_gateway.updateadmin audit action from the write-side enum.packages/db/src/migrations/0291_moaning_wrecker.sql.Verification
pnpm drizzle generatepnpm drizzle:verify-bootstrap— applied the full migration chain against a fresh database.pnpm --filter @kilocode/db test -- schema.test.ts --runInBand(7 tests)pnpm --filter web test -- src/lib/user/index.test.ts src/lib/admin/admin-action-audit.test.ts(197 tests)pnpm --filter @kilocode/db typecheckandlinttsgo --noEmit -p apps/web/tsconfig.jsonpnpm --filter web lintpnpm format:changedandgit diff --checkVisual Changes
N/A
Reviewer Notes
Historical
organization_audit_logsrows that recordedorganization.mcp_gateway.updateremain; that column is text, so no data migration is required. Only new writes of that action are removed.The dropped
mcp_gateway_audit_eventstable contains the gateway's own audit trail. Its retention window was 60 days, and dropping the table deletes it immediately. This is intentional because the feature is being retired.