snok / django-guid

Inject an ID into every log message from a Django request. ASGI compatible, integrates with Sentry, and works with Celery
https://django-guid.readthedocs.io
MIT License
454 stars 27 forks source link

Integration with Dramatiq #117

Open ruslaniv opened 9 months ago

ruslaniv commented 9 months ago

Would it be possible to add integration with Dramatiq message queue?

If not, do you guys have any pointers how I can send a correlation ID into a dramatiq task so I can track how each task spawned by a given request is handled?

sondrelg commented 9 months ago

The celery integration passes correlation IDs from the scheduling process to the worker process by using lifecycle hooks built into the framework. Is there an equivalent mechanism for passing data, in dramatiq?