Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 2 additions & 8 deletions ddtrace/contrib/celery/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
The Celery integration will trace all tasks that are executed in the
background. Functions and class based tasks are traced only if the Celery API
is used, so calling the function directly or via the ``run()`` method will not
generate traces. On the other hand, calling ``apply()``, ``apply_async()`` and ``delay()``
generate traces. However, calling ``apply()``, ``apply_async()`` and ``delay()``
will produce tracing data. To trace your Celery application, call the patch method::

import celery
Expand All @@ -22,13 +22,7 @@ def run(self):

To change Celery service name, you can use the ``Config`` API as follows::

from ddtrace import Pin

app = celery.Celery()

@app.task
def compute_stats():
pass
from ddtrace import config

# change service names for producers and workers
config.celery['producer_service_name'] = 'task-queue'
Expand Down