a year ago
Backend: NestJS + prisma
ENV is DATABASE_URL="${{ name-of-db-service.DATABASE_URL }}"
Attachments
Pinned Solution
a year ago
I would first try switching to pg for your database driver instead of Prisma's default Rust driver.
https://www.prisma.io/docs/orm/overview/databases/postgresql#using-the-node-postgres-driver
19 Replies
a year ago
Hey there! We've found the following might help you get unblocked faster:
- 🧵 Intermittent ECONNRESET / “Connection reset by peer” between NestJS (Prisma) and PostGIS on Railway
- 🧵 Postgres Connection Limit and Timeout
- 🧵 MySQL Issues – Disk Usage and Connection Failure
If you find the answer from one of these, please let us know by solving the thread!
a year ago
Hey there! Do you happen to have multiple connections going at once? If so are you doing connection pooling?
noahd
Hey there! Do you happen to have multiple connections going at once? If so are you doing connection pooling?
a year ago
I'm 100% sure, I know it is possible, but I also noticed it happening when I was the only user accessing the app
oeduardofreitas
I'm 100% sure, I know it is possible, but I also noticed it happening when I was the only user accessing the app
a year ago
I'm not using connection pooling
a year ago
Did a bit of digging, it looks like some users had this same issue then implemented connection pooling with pgbouncer and it solved it!
noahd
Did a bit of digging, it looks like some users had this same issue then implemented connection pooling with pgbouncer and it solved it!
a year ago
I'll try adding the pgbouncer
a year ago
This might be a good thing to take a peek at as well! https://www.prisma.io/docs/orm/prisma-client/setup-and-configuration/databases-connections
Let me know how PGBouncer goes!
a year ago
I would first try switching to pg for your database driver instead of Prisma's default Rust driver.
https://www.prisma.io/docs/orm/overview/databases/postgresql#using-the-node-postgres-driver
brody
I would first try switching to `pg` for your database driver instead of Prisma's default Rust driver. <https://www.prisma.io/docs/orm/overview/databases/postgresql#using-the-node-postgres-driver>
a year ago
sure, I'll do it first
brody
I would first try switching to `pg` for your database driver instead of Prisma's default Rust driver. <https://www.prisma.io/docs/orm/overview/databases/postgresql#using-the-node-postgres-driver>
a year ago
I have made the change, lets see if the error goes away
noahd
Howdy! Did that fix the error?
a year ago
I haven't seen the error anymore. I'll keep monitoring it
noahd
Can i get any more info about the project? Would be awesome!
a year ago
sure, what info would you like?
oeduardofreitas
sure, what info would you like?
a year ago
Oop I think I sent this in the wrong thread accidentally I apologize! Was multitasking with tabs too fast
noahd
Oop I think I sent this in the wrong thread accidentally I apologize! Was multitasking with tabs too fast
a year ago
No worries
a year ago
Resolved by switching to pg the database driver instead of Prisma's default Rust driver
Status changed to Awaiting User Response Railway • about 1 year ago
Status changed to Solved brody • about 1 year ago
