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

Fix RabbitMQ regression in #9383 #9443

Merged
merged 19 commits into from
Jun 29, 2021
Merged

Conversation

srebhan
Copy link
Member

@srebhan srebhan commented Jun 28, 2021

Required for all PRs:

  • Updated associated README.md.
  • Wrote appropriate unit tests.

resolves #9383

This resolves the wrong types for _avg metrics. Those errors went unnoticed before checking the return types (#8992) and returned invalid values (all zero) if the server responded with as floating-point formatted number by chance.
This PR furthermore tries to handle missing plugins (e.g. federation) more gracefully providing the server sent error to the user. To avoid those errors altogether, a (backward-compatible) metric-filter is introduced such that the user can disable erroneous metrics.

@telegraf-tiger telegraf-tiger bot added the fix pr to fix corresponding bug label Jun 28, 2021
@srebhan srebhan added regression something that used to work, but is now broken area/rabbitmq labels Jun 28, 2021
Copy link
Contributor

@akrantz01 akrantz01 left a comment

Choose a reason for hiding this comment

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

Overall LGTM. I just left some comments on some of the type conversion for Memory.Total.

plugins/inputs/rabbitmq/rabbitmq.go Outdated Show resolved Hide resolved
plugins/inputs/rabbitmq/rabbitmq.go Show resolved Hide resolved
plugins/inputs/rabbitmq/rabbitmq.go Outdated Show resolved Hide resolved
@srebhan srebhan requested a review from akrantz01 June 29, 2021 06:54
@srebhan
Copy link
Member Author

srebhan commented Jun 29, 2021

@akrantz01 thanks for review. I changed the code according to your suggestions except for the map[string]interface{} part, which does not work otherwise.

@sspaink sspaink merged commit e2ab218 into influxdata:master Jun 29, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/rabbitmq fix pr to fix corresponding bug regression something that used to work, but is now broken
Projects
None yet
Development

Successfully merging this pull request may close these issues.

RabbitMQ Input Plugin v1.19.0 unmarshal errors
3 participants