#34870: Memory leak when using psycopg-c with django hstore -------------------------------------+------------------------------------- Reporter: David Burke | Owner: nobody Type: Bug | Status: closed Component: Database layer | Version: 4.2 (models, ORM) | Severity: Normal | Resolution: invalid Keywords: | Triage Stage: | Unreviewed Has patch: 0 | Needs documentation: 0 Needs tests: 0 | Patch needs improvement: 0 Easy pickings: 0 | UI/UX: 0 -------------------------------------+-------------------------------------
Comment (by Florian Apolloner): Ok, raising an exception could cause problems, but as far as that traceback is concerned I am reading the following out of it: * Django registers the hstore type once per connection. This makes sense since connections to multiple databases might have different hstore oids (In older versions of Django we might have registered types globally for psycopg once, but I think with psycopg3 this got improved). * Django only queries the database once per alias since `get_hstore_oids` is cached. So from the looks of it it seems as if celery opens a new connection per task which is kinda (?) wasteful. But it is definitely not a bug in Django. -- Ticket URL: <https://code.djangoproject.com/ticket/34870#comment:8> Django <https://code.djangoproject.com/> The Web framework for perfectionists with deadlines. -- You received this message because you are subscribed to the Google Groups "Django updates" group. To unsubscribe from this group and stop receiving emails from it, send an email to django-updates+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/django-updates/0107018ad1d2486d-9e6972ab-2ee3-40c6-81cf-dc00ef66fcb2-000000%40eu-central-1.amazonses.com.