High Response Time on Express.js API
anl404
HOBBYOP

a month ago

Hello Railway Support Team,

I’m currently hosting an Express.js REST API connected to a Supabase PostgreSQL database on the Hobby plan. Despite having optimized my code and database queries, I’m consistently experiencing response times around 1–2 seconds per request.

For example, even simple GET requests that should return lightweight JSON data take over one second on average. I’ve tested both locally and from different regions, and the latency seems to come from the server’s cold start or general performance.

Could you please check if there are any performance limitations, cold start delays, or configuration issues related to my project environment? Any guidance on improving response speed on the Hobby plan would be appreciated.

Thank you in advance for your help!

$10 Bounty

5 Replies

Railway
BOT

a month ago

Hey there! We've found the following might help you get unblocked faster:

If you find the answer from one of these, please let us know by solving the thread!


brody
EMPLOYEE

a month ago

This thread has been marked as public for community involvement, as it does not contain any sensitive or personal information. Any further activity in this thread will be visible to everyone.

Status changed to Open brody about 1 month ago


fra
HOBBY

a month ago

Is this only with the first request or with all the requests? If this is only with the first request check if you have the serverless enabled and try to disable it...


fra

Is this only with the first request or with all the requests? If this is only with the first request check if you have the serverless enabled and try to disable it...

anl404
HOBBYOP

a month ago

It usually happens only on the first request, I get a response in about 8–10 seconds. Subsequent requests take around 300–800 ms. However, if I don’t send any requests for about 2 minutes, the next request again takes around 10 seconds to respond.

I’ve already moved my database to Railway.com and I’m also using Redis, but nothing changed.


anl404
HOBBYOP

a month ago

Already that serverless mode is disabled.


fra
HOBBY

a month ago

Are all your services not serverless and in a region near you?


Loading...