1

I just updated my python app running in heroku to point cockroachdb cloud DB. I am using the psycopg2 python library. Here is the exception I am running into:

2021-06-16T13:07:40.857022+00:00 app[web.1]: Oops! An exception has occured: FATAL:  CodeProxyRefusedConnection: Connection attempt throttled
2021-06-16T13:07:40.857074+00:00 app[web.1]: 
2021-06-16T13:07:40.857077+00:00 app[web.1]: Exception TYPE: <class 'psycopg2.OperationalError'>
2021-06-16T13:07:40.857078+00:00 app[web.1]: I am unable to connect to the database
2021-06-16T13:07:40.860470+00:00 app[web.1]: [2021-06-16 13:07:40 +0000] [7] [ERROR] Exception in worker process
2021-06-16T13:07:40.860471+00:00 app[web.1]: Traceback (most recent call last):

I run the same application on gunicorn/flask and it runs fine.

Any ideas on what could be the issue with running this app on heroku?

Here is the app that I am trying to deploy to Heroku: https://github.com/saqib-ali/hivemined

It is currently deployed to Digital Ocean App Platform, and connects to CockroachCloud without any issues.

Saqib Ali
  • 3,953
  • 10
  • 55
  • 100
  • I see that you're getting some help at https://forum.cockroachlabs.com/t/accessing-cockroachcloud-db-from-python-app-running-in-heroku/4613/5 – rafiss Jun 16 '21 at 21:03
  • @rafiss, yea i am trying to see if there is something on the heroku side that needs to be configured. Still no luck getting the cockroachcloud working with heroku app. – Saqib Ali Jun 17 '21 at 03:32

0 Answers0