Ultimate

Migrating from Node and Drizzle

The concept map for a Node app on Drizzle ORM — Express, Fastify, Hono or Next.js route handlers in front. The runbook — phases, exit conditions, stop conditions — is Migrating an existing app; this page says what each term becomes. As of 2026-11 (orm.drizzle.team).

Concept map

Node / DrizzleUltimate
an Express / Fastify / Hono route that rendersa route file: Routes and render modes
a route handler that writes, a tRPC mutationan action: Actions
a tRPC query, a GET handlera query: Queries and live queries
a pgTable() declarationan entity(): Entities and migrations
drizzle-kit generate, migratex db gen "<name>", then x db migrate
a Zod schema on a handlerthe action's input: Actions
BullMQ, pg-bossa job: Jobs and workflows
node-cron, a repeatable joba task: Scheduled tasks
Passport, Auth.js, LuciaAuth
CASL, hand-written middleware checksa policy: Policies and authz
Socket.IO, wsa live query: Realtime
NodemailerMail
S3 SDK callsStorage and uploads
Vitest, Jestbun test through Testing
node server.js, next devx dev

What does not map

Node / DrizzleWhy
Node-only APIs and native addonsBun only: check each against Bun's own list, bun.sh/docs/runtime/nodejs-apis
MySQL, SQLite (mysqlTable, sqliteTable)Postgres only, by design: Home
React componentspages render with SolidJS; interactive parts are islands. No converter
a serverless or edge deploy targetcontainers only: Deployment

Schema adoption

Drizzle already declares tables in TypeScript, so the shape carries over column by column; ids are whatever the app chose. Phase 1 of the runbook declares the existing tables with the physical-name overrides and type map it gives, then x db gen until x verify --only drift agrees: Migrating an existing app.

Identity cutover

The app storesBranch
bcrypt / bcryptjs hashes ($2a$, $2b$)proceed: verified natively, rewritten as argon2id on first login (Migrating an existing app)
argon2 hashes ($argon2id$)proceed: rehashed when weaker than the policy
scrypt, PBKDF2, anything else⛔ stop: no verifier ships. Keep the old login as a bridge, or force a reset
a JWT or a session tablebridge it with your own verifier behind configureAuthenticator() (Auth)

Edit this page on GitHubThis page as markdown