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

[internal/filter] Add filterottl functions with additional options #37271

Conversation

edmocosta
Copy link
Contributor

Description

The transformprocessor is currently using the internal/filter/filterottl to create conditions expressions. In order to support path's with context prefix, it needs to configure the underline ottl.Parser using their EnablePathContextNames options. This PR changes this internal API adding new functions that accepts the parsers options as argument.

Link to tracking issue

Related to #29017

Testing

Unit tests

@edmocosta edmocosta changed the title [filterottl] Add filterottl functions with additional options [internal/filter] Add filterottl functions with additional options Jan 16, 2025
@edmocosta edmocosta marked this pull request as ready for review January 16, 2025 13:21
@edmocosta edmocosta requested a review from a team as a code owner January 16, 2025 13:21
@edmocosta edmocosta requested a review from codeboten January 16, 2025 13:21
@TylerHelmuth TylerHelmuth added the Skip Changelog PRs that do not require a CHANGELOG.md entry label Jan 16, 2025
@TylerHelmuth TylerHelmuth merged commit cab9457 into open-telemetry:main Jan 16, 2025
180 of 181 checks passed
@github-actions github-actions bot added this to the next release milestone Jan 16, 2025
chengchuanpeng pushed a commit to chengchuanpeng/opentelemetry-collector-contrib that referenced this pull request Jan 26, 2025
…pen-telemetry#37271)

<!--Ex. Fixing a bug - Describe the bug and how this fixes the issue.
Ex. Adding a feature - Explain what this achieves.-->
#### Description
The `transformprocessor` is currently using the
`internal/filter/filterottl` to create `conditions` expressions. In
order to support path's with context prefix, it needs to configure the
underline `ottl.Parser` using their `EnablePathContextNames` options.
This PR changes this internal API adding new functions that accepts the
parsers options as argument.


<!-- Issue number (e.g. open-telemetry#1234) or full URL to issue, if applicable. -->
#### Link to tracking issue
Related to
open-telemetry#29017

<!--Describe what testing was performed and which tests were added.-->
#### Testing
Unit tests

<!--Please delete paragraphs that you did not use before submitting.-->
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
internal/filter Skip Changelog PRs that do not require a CHANGELOG.md entry
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants