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(parsers.xpath): Ensure precedence of explicitly defined tags and fields #13662

Merged
merged 4 commits into from
Jul 26, 2023

Conversation

srebhan
Copy link
Member

@srebhan srebhan commented Jul 24, 2023

based on #13660

This PR ensures that explicitly defined tags and fields will override their batch-counterparts if a tag or field name is reused. This can be helpful in case you want to type-convert only one field out of many (potentially unknown ones) and thus need to override only one field value.

@telegraf-tiger telegraf-tiger bot added fix pr to fix corresponding bug plugin/parser 1. Request for new parser plugins 2. Issues/PRs that are related to parser plugins labels Jul 24, 2023
Copy link

@jcpunk jcpunk left a comment

Choose a reason for hiding this comment

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

Works for me

@srebhan srebhan force-pushed the xpath_explicit_field_precedence branch from 9920f77 to fb6bc2b Compare July 26, 2023 13:58
@srebhan srebhan added the ready for final review This pull request has been reviewed and/or tested by multiple users and is ready for a final review. label Jul 26, 2023
Copy link
Contributor

@powersj powersj left a comment

Choose a reason for hiding this comment

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

I'm a little concerned about regressions and/or corner cases that our previous tests do not cover, but this does seem to clean up the behavior.

@powersj powersj merged commit da28cfd into influxdata:master Jul 26, 2023
@github-actions github-actions bot added this to the v1.27.3 milestone Jul 26, 2023
powersj pushed a commit that referenced this pull request Jul 31, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
fix pr to fix corresponding bug plugin/parser 1. Request for new parser plugins 2. Issues/PRs that are related to parser plugins ready for final review This pull request has been reviewed and/or tested by multiple users and is ready for a final review.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants