jenkinsci / datadog-plugin

A Jenkins plugin used to forward metrics, events, and service checks to an account at Datadog, automatically.
https://plugins.jenkins.io/datadog/
MIT License
30 stars 48 forks source link

CI Traces not being sent to agent because BuildSpanAction is null #409

Closed prescottatloopio closed 3 months ago

prescottatloopio commented 3 months ago

Describe the bug No data is being sent to the Datadog tracer agent on our server for any of the jobs being run, instead we see a log message like this in our System Log: Unable to set trace ids as environment variables. in Run 'loopio-app » Pull Requests » sub-jobs » react-unit-tests #3517'. BuildSpanAction is null

To Reproduce Steps to reproduce the behavior:

  1. Install the Datadog Agent on your Jenkins server as per the documentation
  2. Install the Jenkins Datadog plugin
  3. Enable CI Tracing in the Datadog section of the Configure System screen
  4. Test the connection to the trace port successfully
  5. Go to the System Log and find the Datadog logs that include "Unable to set trace ids as environment variables" and "BuildSpanAction is null"
  6. Check your tracker-agent.log on your server to find "No data received"

Expected behavior After installing the plugin, I expected it to send build data to the installed Datadog agent, but no data is being sent

Screenshots

Environment and Versions (please complete the following information): A clear and precise description of your setup: Jenkins 2.426.3 Datadog Plugin Version 6.0.2 Datadog agent agent 7.52.1

Additional context I don't know exactly how to reproduce it because I took the exact same steps on two different Jenkins servers and it is working on one of them, but we're getting this error on the other one. It could come down to some sort of minor configuration difference, which if you can point me in the right direction to update, I can close this ticket. But I can't find any reference to the error we are seeing in the logs anywhere besides in the Github source code

nikita-tkachenko-datadog commented 3 months ago

Hi @prescottatloopio, I believe you have also raised a ticket with the Datadog support for this issue. As the ticket was closed, I am closing this one as well. Let me know if you're still experiencing any problems though. Thanks!