Slow DB connections from Singapore region

We are running several API applications with fly.io from sin region (Singapore). Our database is hosted in Amazon RDS in eu-west-1 (Ireland).

In some of those applications, for example law-lab-api, we are experiencing slow DB connections. Requests are taking 5-10 seconds to fulfill. Some requests are experiencing timeout (timeout is set to 15 seconds). For those timeout events, Amazon RDS is throwing this error:

LOG: could not receive data from client: Connection timed out

These applications are also experiencing database disconnect issue after some timeouts.

When we connect the RDS database from the application in localhost, the database responds immediately. So there’s no slow db query issues.

We have some fast applications hosted in fly.io’s Singapore region, for example bsaa-api. They use the same RDS instance from Ireland and are quite fast. So Amazon RDS instance being in Ireland is not an issue.

So we have been wondering whether the applications with slow db connections are somehow being throttled by fly.io’s proxy. Kindly have a look at the following applications which are experiencing slow db connection and check whether their db connections are being throttled.

law-lab-api
elite-garments-api
interport-api
nz-tex-api

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.