Bogdanp / django_dramatiq

A Django app that integrates with Dramatiq.
https://dramatiq.io
Other
331 stars 77 forks source link

Doesn't close DB connections leading to "FATAL: sorry, too many clients already" #86

Open Volpym opened 3 years ago

Volpym commented 3 years ago

Hi!

I have 5 tasks that run periodically (using periodiq) and each time they these are executed they open a new connection to the database.

Already tried the middleware ordering showcased on issue #76.

Thank you in advance

agamrp commented 3 years ago

@Volpym did you end up figuring out what was causing this? I'm running into the same thing.

Volpym commented 3 years ago

@agamrp unfortunately no.

agamrp commented 3 years ago

@agamrp unfortunately no.

@Volpym Thanks for getting back to me, if you don't mind me asking, did you end up using something else besides dramatiq for your use case?

Volpym commented 3 years ago

@agamrp unfortunately no.

@Volpym Thanks for getting back to me, if you don't mind me asking, did you end up using something else besides dramatiq for your use case?

@agamrp Due to lack of time, I had to use another module (not sure if I'm allowed to share its name but with a google search you will find it).

helsonxiao commented 2 years ago

In case someone still have this problem.

Try to use the latest version. These two lines should fix it. https://github.com/Bogdanp/django_dramatiq/blob/v0.10.0/django_dramatiq/middleware.py#L68-L69

Schulzjo commented 1 year ago

also mentioned: https://github.com/Bogdanp/django_dramatiq/issues/76 ?