PostgresError: sorry, too many clients already
this is the client
I'm calling it like this, suddenly it says
3 Replies
@moderator need help
it happens again
👋 is it next js?
If so, it is probably due to hot reload that recreates again and again a Drizzle client. The solution for this is to persist (for dev env only) the client in globalThis.
yes nextjs, okay thank you for your help~