Skip to content

feat(database): brownfield support — introspector, drift detection, db CLI#356

Draft
ditadi wants to merge 9 commits intostack/database/serverfrom
stack/database/brownfield
Draft

feat(database): brownfield support — introspector, drift detection, db CLI#356
ditadi wants to merge 9 commits intostack/database/serverfrom
stack/database/brownfield

Conversation

@ditadi
Copy link
Copy Markdown
Contributor

@ditadi ditadi commented May 6, 2026

🥞 Stacked PR

Use this link to review incremental changes.


Brownfield support for existing Lakebase/Postgres schemas. This layer lets AppKit inspect a live database, render schema files, detect drift, and manage migrations from the CLI.

Introspection + rendering

Adds the introspector engine, Drizzle adapter, schema-to-introspection bridge, SQL rendering, type mapping, and roundtrip tests.

Drift detection

Adds boot-time drift detection with fatal/warn classifications, production fail-closed behavior for unsafe drift, live-only warnings, healthz saturation, and pg-to-http error mapping.

Database CLI

Adds appkit db introspect, generate, migrate, verify, setup:dev, seed, and migration helpers.

Test plan

  • Introspector adapter tests
  • Render and roundtrip tests
  • Drift tests
  • CLI command tests
  • Full stack verification run locally before push

Signed-off-by: Victor Ditadi victor.ditadi@databricks.com

PR Stack

  1. Database foundation: schema builder, plugin skeleton, runtime base — feat(database): foundation — schema builder, plugin skeleton, connectors #354
  2. Server runtime: Drizzle pool, OBO, transactions, hooks — feat(database): server runtime — drizzle pool, OBO, transactions, hooks #355
  3. Brownfield support: introspector, drift detection, db CLI (this PR)
  4. appkit db init onboarding — feat(cli): appkit db init — one-command lakebase onboarding #357
  5. Typed browser db client + dev playground demo — feat(database): typed browser db client + dev playground demo #358
  6. React entity UI + columns metadata — feat(database): React entity UI components + columns metadata route #359
  7. RLS scaffolder + connection pool tuning — feat(database): RLS scaffolder + connection pool tuning #360
  8. Database plugin guide + release polish — docs(database): plugin guide + CLAUDE.md polish + small public-API tweaks #361

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant