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

feat: add dd-trace to edxapp workers #6

Merged
merged 8 commits into from
May 20, 2024

Conversation

connorhaugh
Copy link

Configuration Pull Request

This PR adds dd-trace to the workers so we can monitor them (and celery tasks). It does not require dd to be enabled.

Make sure that the following steps are done before merging:

  • Have a Site Reliability Engineer review the PR if you don't own all of the services impacted.
  • If you are adding any new default values that need to be overridden when this change goes live, update internal repos and add an entry to the top of the CHANGELOG.
  • Performed the appropriate testing.
  • Think about how this change will affect Open edX operators and update the wiki page for the next Open edX release if needed

{% endif %}

{% if EDXAPP_DATADOG_ENABLE %}
{% set executable = edxapp_venv_bin + '/ddtrace-run ' + executable %}
export DD_TAGS=("service:edx-edxapp-{{ SERVICE_VARIANT }}-workers", "queue:{{EDX_REST_API_CLIENT_NAME}}")
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  1. I don't think array syntax will work here. I believe what we want is this:
    Suggested change
    export DD_TAGS=("service:edx-edxapp-{{ SERVICE_VARIANT }}-workers", "queue:{{EDX_REST_API_CLIENT_NAME}}")
    export DD_TAGS="service:edx-edxapp-{{ SERVICE_VARIANT }}-workers,queue:{{EDX_REST_API_CLIENT_NAME}}"
  2. Do we want edx-edxapp-VARIANT-workers, or edx-edxapp-workers-VARIANT? The latter would be a better match for what we have in New Relic.
  3. Rather than introducing a secondary use for EDX_REST_API_CLIENT_NAME can we set an environment variable in the workers.conf like EDXAPP_WORKERS_QUEUE? Otherwise we end up yoking those two features together.

Co-authored-by: Tim McCormack <tmccormack@edx.org>
@connorhaugh connorhaugh merged commit e9b5d83 into master May 20, 2024
4 checks passed
@connorhaugh connorhaugh deleted the feat--add-dd-trace-to-edxapp-workers branch May 20, 2024 13:08
connorhaugh added a commit that referenced this pull request May 20, 2024
connorhaugh added a commit that referenced this pull request May 20, 2024
Caused AnsibleUndefinedVariable: 'SERVICE_VARIANT' is undefined in edxapp deploy script.
This reverts commit e9b5d83.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants