Connection to Redshift database through Ruby on Rails, blazer hanging and failing

284 Views Asked by At

In a Ruby on Rails 6 project, I am using the blazer gem and whenever I add an AWS redshift database, the connection keeps hanging and loading for a long time, and then fails

PG::ConnectionBad: could not connect to server: Connection timed out
    Is the server running on host "redshift-cluster-x.xxxxxxx.us-east-x.redshift.amazonaws.com" (34.xx.30.xxx) and accepting
    TCP/IP connections on port 5439?

Connection

# data_source.settings["url"] = redshift://username:password@redshift-cluster-1.xxxxx.us-east-1.redshift.amazonaws.com:5439/dev
establish_connection(data_source.settings["url"])

. I have the activerecord6-redshift-adpater gem installed

enter image description here

Ensured public access enter image description here

Also, the VPC routes

enter image description here

0

There are 0 best solutions below