Dataset Scheduled Refresh Fails with CONNECTION_FAILURE (PostgreSQL RDS) – Query Reaches DB But Fails After a Few Minutes

Hi everyone,

Since July 9, I’ve been encountering an issue with a scheduled refresh on a dataset in Amazon QuickSight that connects to a PostgreSQL RDS instance. The dataset fails to refresh and shows the following error:

Error type:  
CONNECTION_FAILURE  

Amazon QuickSight can’t connect to your data source. Check the data source connection settings and try again.

Error details:  
An I/O error occurred while sending to the backend.

However, upon investigation I’ve confirmed the following:

  • The database connection is working – I can manually connect from QuickSight and other tools.
  • When the refresh starts, I can see the query being executed in the PostgreSQL logs and in the RDS Performance Insights, meaning the query does reach the backend and starts processing.
  • Despite that, the refresh fails after 3 to 5 minutes, consistently.

There have been no changes on my end to the dataset or connection settings that coincide with this issue starting.

My Questions:

  • Has anyone else experienced a similar issue starting in July?
  • Could this be related to an internal QuickSight timeout or a recent update/change in how QuickSight manages connections?
  • Is there any way to get more detailed logs or diagnostics from QuickSight for these failures?
  • Are there known limits or best practices for long-running queries in scheduled dataset refreshes?

Any help or guidance would be much appreciated!

Thanks in advance,
Javier

Hi @javierReworth

Welcome to the community!

I haven’t used Postgres, but have experience dealing with mySQL.

From my experience you need to look at your database and see if the query that is issued by QuickSight and captured in your database does work completely or times out in the database level itself through your querying tool.

Query plans do change once QuickSight’s incremental refresh time conditions gets put in and I have had cases where I had to tweak my Custom SQL Queries a bit to make them work. I had refresh failures with a generic error but not a connection timeout error.

Regards,
Giri