Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Celery Instrumentation with apply_async function #876

Closed
ardecode opened this issue Jul 1, 2020 · 0 comments · Fixed by #1135
Closed

Celery Instrumentation with apply_async function #876

ardecode opened this issue Jul 1, 2020 · 0 comments · Fixed by #1135
Assignees
Labels
bug Something isn't working

Comments

@ardecode
Copy link

ardecode commented Jul 1, 2020

I have a basic django application which uses celery to call a method using apply_async and delay functions. I am trying to integrate Otel into my django application. I am using 0.10b0 version of all Otel libraries. I have used celery-auto instrumentation for produce the spans/traces. But I see that the celery-auto instrumentation isnt working.

Steps to reproduce
I have attached my code in order to reproduce the issue.

  1. Run the python application using
    python manage.py runserver

Screen Shot 2020-07-01 at 1 54 05 PM

  1. Then also start the celery worker using
    celery -A django_email_celery worker --loglevel=info

Screen Shot 2020-07-01 at 1 55 11 PM

What is the expected behavior?
Once you hit the localhost url, I see the trace and spans created by the Otel. But I was expecting the traceid to continue from method index() in views.py to send_log in tasks.py.

What is the actual behavior?
But then the a new trace is being created at the send_log.
Screen Shot 2020-07-01 at 1 59 29 PM
Screen Shot 2020-07-01 at 2 01 44 PM

Other Info
I have added celery instrumentation in celery.py file

django_email_celery.zip

@ocelotl @codeboten

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
2 participants