Deployment server issue.
wasayhatzs
FREEOP

3 months ago

I’ve deployed my backend on Railway with a database connected. The issue is that it works fine for a while after I deploy, but then it just stops responding. Whenever I hit the backend with a request, it times out and doesn’t reply in time.
Right now I have to redeploy once or twice a day just to get it working again, which is pretty frustrating. I also have a big meeting today and really don’t want this to mess things up.
Can you please help me figure out what’s going on, or fix it from your side if possible?
project id: edf11695-2a90-4573-a360-85b19c89ac7d
service: f02f072c-d0d7-46f9-b79f-fb9f8de4cd1c
service 2: 5484d7cb-596b-46e6-92e1-7219766f47ad

Both of these services are same repo please fix this asap.

$30 Bounty

1 Replies

irazvan2745
PRO

3 months ago

have you checked the logs of the db?


wasayhatzs
FREEOP

3 months ago

i have a big meeting today. please help me out


wasayhatzs
FREEOP

3 months ago

yes i did the db takes too long to repond and always request fails after some time of deployement with 502


wasayhatzs
FREEOP

3 months ago

i have deployed same backend on ngrok and it was working fine over there


irazvan2745
PRO

3 months ago

Is the db serverless?


wasayhatzs
FREEOP

3 months ago

no the db is not serverless i think we are using noraml db of yours


wasayhatzs
FREEOP

3 months ago

we are facing this same issue from friday


irazvan2745
PRO

3 months ago

are the services in the same project?


wasayhatzs
FREEOP

3 months ago

yes


irazvan2745
PRO

3 months ago

hmm


wasayhatzs
FREEOP

3 months ago

i have other services over there aswell every other service is working fine just facing issue with these 2 services


irazvan2745
PRO

3 months ago

you should add some better logging to your backend to identify the exact issue


wasayhatzs
FREEOP

3 months ago

we already did that it didn't helped much so we deployed on ngrok so we can identify issue in a better way


wasayhatzs
FREEOP

3 months ago

let me show you something


irazvan2745
PRO

3 months ago

i honestly have no idea


irazvan2745
PRO

3 months ago

hm


irazvan2745
PRO

3 months ago

maybe someone else can help you, sorry


wasayhatzs
FREEOP

3 months ago

HTTP Status Code: 502 (Bad Gateway) for ALL requests
Error Rate: 100.00% (1,000 out of 1,000 requests failed)
Response Time: Extremely high at 15.59 seconds average
📈 Performance Metrics
Response Times:
Average: 15.59 seconds (extremely slow)
Minimum: 15.55 seconds
Maximum: 15.74 seconds
95th Percentile: 15.68 seconds


wasayhatzs
FREEOP

3 months ago

not a problem but i'll be very greatful if someone could help me out


wasayhatzs
FREEOP

3 months ago

  • Server Overload: Your Railway deployment is likely overwhelmed by the load.

  • Resource Exhaustion: The server may have run out of memory, CPU, or database connections

  • Timeout Issues: The server is taking too long to respond, causing timeouts


wasayhatzs
FREEOP

3 months ago

can anyone can guide me on this
Railway rate limit of 500 logs/sec reached for replica, update your application to reduce the logging rate. Messages dropped: 2164


wasayhatzs
FREEOP

3 months ago

Brody can you help me out over here.


brody
EMPLOYEE

3 months ago

Where are you located geographically?


wasayhatzs
FREEOP

3 months ago

Pakistan


wasayhatzs
FREEOP

3 months ago

Asia


wasayhatzs
FREEOP

3 months ago

i have added some better logging

1414418611862503700


brody
EMPLOYEE

3 months ago

I would start by making sure all your services are in the Asia region. Most of your services are not deployed to our Asia region.


wasayhatzs
FREEOP

3 months ago

becuase our services are being used in us


wasayhatzs
FREEOP

3 months ago

so most are deployed on different region


brody
EMPLOYEE

3 months ago

Then make sure they are all located closest to the users.

The next step would be to make sure the connection to the database is done via the private network.


wasayhatzs
FREEOP

3 months ago

how am i supposed to know this that the connection is via private or public


brody
EMPLOYEE

3 months ago

If you have your backend connect to the database via the TCP proxy, then you are connecting to it via the public network.


wasayhatzs
FREEOP

3 months ago

we simply connected mysql with our node application using credetials provided by railway


wasayhatzs
FREEOP

3 months ago

then public network it is


brody
EMPLOYEE

3 months ago

Have your backend connect to the database via the private network.


wasayhatzs
FREEOP

3 months ago

how to do that


wasayhatzs
FREEOP

3 months ago

i dont have much time


wasayhatzs
FREEOP

3 months ago

like do i have to do extra things in my backend?


wasayhatzs
FREEOP

3 months ago

it'll be great if you could guide me


brody
EMPLOYEE

3 months ago

Let's start by doing step 1 first.

Then make sure they are all located closest to the users.


wasayhatzs
FREEOP

3 months ago

i'm in a do or die situation.


wasayhatzs
FREEOP

3 months ago

the meeting is in us and my application would be tested there.


wasayhatzs
FREEOP

3 months ago

whats the first step


wasayhatzs
FREEOP

3 months ago

please dont mind. if i miss anything


wasayhatzs
FREEOP

3 months ago

you just tell me it'll be done


brody
EMPLOYEE

3 months ago

I've bountied this thread so that other community members may come to your aid.

https://discord.com/channels/713503345364697088/1372169430091698289/1414420449273577472


wasayhatzs
FREEOP

3 months ago

tysm sir


irazvan2745
PRO

3 months ago

Are you sure its all connected? edit the app so that it console logs the db credentials


Loading...