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

Enable python and django monitoring in kafka consumers and celery workers #785

Open
robrap opened this issue Aug 28, 2024 · 4 comments
Open
Assignees

Comments

@robrap
Copy link
Contributor

robrap commented Aug 28, 2024

This probably should be two separate tasks (kafka consumers and celery workers), but adding one to start to capture the ideas.

Implementation thoughts:

  • In Datadog, I'm not sure if the Python version can be seen manually. This might need to be asked in a DD support ticket.
  • These changes may highlight where DatadogBackend is missing in other services, and thus they might be missing all custom span tags. So this dashboard might serve as a useful verification that all services are set up correctly.
    • Of course we'd need to expand the operation_name on this dashboard to include celery and kafka consumer related operations.
  • Take the part of DeploymentMonitoringMiddleware that actually sets the custom attributes, and make it into a utility method that could be used from outside the middleware as well
  • In event-bus-kafka, we could add a call to this new method here. Reminder: add an edx-django-utils minimum constraint in base.in to ensure it gets published as part of the package.
  • The Celery change is a little trickier, only because we don't have a mechanism set up to plug in to all services yet (although this is very close).
    • It would probably need to be implemented in a plugin. It would either use a celery signal or DD hook as mentioned in Automatically set code owner for celery tasks #729.
    • If the plugin were defined in edx-django-utils, it would get added to all services (once the new plugin endpoint were defined and added to each service), because this library is already installed in each service.
      • The trouble with doing this in edx-django-utils is that it probably won't work for New Relic. That said, the feature benefits the entire community for upgrades, so hopefully this would be acceptable.
      • The alternative would be to create a 2u-django-utils repo that privately gets deployed to all our services. This is a nice-to-have capability in the long run, but would take additional work, so we'd need to consider if it is worth it.
@robrap
Copy link
Contributor Author

robrap commented Feb 21, 2025

@robrap: Note to self: Determine if any of this is still valid, or if it is all complete, and then clean-up this ticket.

@robrap robrap self-assigned this Feb 21, 2025
@robrap robrap moved this to Backlog in Arch-BOM Feb 21, 2025
@UsamaSadiq UsamaSadiq assigned UsamaSadiq and unassigned robrap Feb 24, 2025
@UsamaSadiq UsamaSadiq moved this from Backlog to In Progress in Arch-BOM Feb 24, 2025
@UsamaSadiq UsamaSadiq moved this from In Progress to Backlog in Arch-BOM Feb 24, 2025
@UsamaSadiq UsamaSadiq moved this from Todo to In Progress in Arbi-BOM Feb 24, 2025
@UsamaSadiq
Copy link
Member

@robrap I noticed you had assigned this issue to yourself. Would you prefer to work on this yourself. I'll remove this from arbi-bom board in that case.

@robrap
Copy link
Contributor Author

robrap commented Feb 24, 2025

@UsamaSadiq: You are welcome to take this. I will only note that this ticket is from early in the DD migration, so some of it is no longer relevant. As a first step, please help determine what is actually still needed, if anything. Thank you!

@UsamaSadiq
Copy link
Member

DatadogBackend was verified to be present in all services and the Datadog migration tracking sheet was updated in the issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: In Progress
Status: Backlog
Development

No branches or pull requests

3 participants