-
Notifications
You must be signed in to change notification settings - Fork 49
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
Don't continuously log messages whenever no API token is configured #55
Comments
Thanks for opening this issue. I am not sure i understand the use case here. Are you using the DogStatsD or the Datadog Agent to report data to Datadog? If so it could to be a bug. However, it seems to me that you just installed the plugin and didn't configure it to sent any data. What is the purpose then? |
Hi @gzussa, looping in re: above:
That's correct - my concern was that when the plugin has not yet been configured, the logs are being spammed. The same would be true if the API token were to expire or become invalid. The issue isn't that it writes to the jenkins log, but that it does it so often, meaning that when it does occur, the log is essentially no use for triaging any other issues. Regardless if the plugin is configured or not (or if the API token expired, as another example), it shouldn't be spamming the log so frequently, regardless of the log level. in the example above, it was writing 17 log lines in 40 seconds to the jenkins log |
Ok i see your point, I notified the team in charge of the plugin and they will take a look. Feel free to open a support ticket if it needs to be escalated. |
Thanks for your contribution! This issue has been automatically marked as stale because it has not had activity in the last 30 days. Note that the issue will not be automatically closed, but this notification will remind us to investigate why there's been inactivity. Thank you for participating in the Datadog open source community. If you would like this issue to remain open:
|
Unmarking as stale- we are currently working on this. |
Actually the secondary fix to avoid running the task when no api token is valid too. |
My PR #63 should fix a noise logger and avoid logging severe logs when no API key is defined. |
Describe the bug
Whenever no API token is configured for the datadog plugin, the plugin will continuously write to the jenkins system log, to this affect.
As a result, the jenkins system log is in affect useless as when debugging jenkins issues, the logs have likely already been rotated.
As an example, the plugin has written 17 log lines in 39 seconds:
FYI, this is not the same issue reported here - while they are both related in the same area, the below was a regression which meant the logs were firing as exceptions:
To Reproduce
Steps to reproduce the behavior:
Expected behavior
The datadog plugin should not be spamming the jenkins log in such a way, that it makes it un-usable for debugging other issues which may occur.
Other plugins, such as the github plugin, do write to the log when an API token is not valid, e.g when it fails to create webhooks, but not in such high frequency.
Additional context
We operate an environment where we provide jenkins masters to other teams, maintaining a core set of plugins. Not all teams will leverage the plugins we have installed, such as the datadog plugin, and may not configure an API token for the plugin.
Others may have expired API tokens and as a result, if we need to debug any issues, the logs are not usable.
The text was updated successfully, but these errors were encountered: