Skip to content

feat(db-vercel-postgres): migrate from deprecated @vercel/postgres to successor @neondatabase/serverless#16227

Open
siimsams wants to merge 3 commits intopayloadcms:mainfrom
siimsams:migrate-vercel-postgres-to-neon-serverless
Open

feat(db-vercel-postgres): migrate from deprecated @vercel/postgres to successor @neondatabase/serverless#16227
siimsams wants to merge 3 commits intopayloadcms:mainfrom
siimsams:migrate-vercel-postgres-to-neon-serverless

Conversation

@siimsams
Copy link
Copy Markdown
Contributor

@siimsams siimsams commented Apr 9, 2026

What?

Migrates db-vercel-postgres from the deprecated @vercel/postgres package to @neondatabase/serverless.

Why?

@vercel/postgres has been deprecated and is no longer maintained. All Vercel Postgres stores have been migrated to Neon's native integration.

On top of that, its VercelPool extends @neondatabase/serverless's Pool (not pg's), which is incompatible with drizzle-orm@0.45.2's stricter NodePgClient type — so continuing to depend on @vercel/postgres forces type-casting workarounds.

How?

  • Replace @vercel/postgres with @neondatabase/serverless in packages/db-vercel-postgres.
  • Use drizzle-orm/neon-serverless for remote Neon connections and keep drizzle-orm/node-postgres for local connections (localhost / 127.0.0.1).
  • Update VercelPostgresAdapter types to reference @neondatabase/serverless's Pool / PoolConfig and NeonDatabase, and refresh the related JSDoc.

Fixes #13404

Extracted from: #16168

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant