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

[pkg/ottl] Add Hex() convertor #33450

Merged
merged 5 commits into from
Jul 3, 2024

Conversation

odubajDT
Copy link
Contributor

@odubajDT odubajDT commented Jun 10, 2024

Description:
Adds a Hex function to the OTTL package. This function can be applied to following values:

  • float64
  • string
  • bool
  • int64
  • []byte

The resulting value will be of type []byte.

Link to tracking Issue: #31929

Testing:

  • unit tests
  • e2e tests

Depends on #33536

@odubajDT odubajDT changed the title Add hex function [pkg/ottl] Add support for converting values to hex Jun 10, 2024
@odubajDT odubajDT marked this pull request as ready for review June 10, 2024 12:33
@odubajDT odubajDT requested a review from a team June 10, 2024 12:33
pkg/ottl/expression.go Outdated Show resolved Hide resolved
pkg/ottl/ottlfuncs/README.md Outdated Show resolved Hide resolved
pkg/ottl/ottlfuncs/README.md Outdated Show resolved Hide resolved
@odubajDT odubajDT force-pushed the add-hex-function branch 4 times, most recently from f954131 to dca05f5 Compare June 11, 2024 07:38
@odubajDT odubajDT marked this pull request as draft June 21, 2024 09:14
@odubajDT odubajDT changed the title [pkg/ottl] Add support for converting values to hex [pkg/ottl] Add Hex() convertor Jun 21, 2024
Copy link
Contributor

@evan-bradley evan-bradley left a comment

Choose a reason for hiding this comment

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

I think we should change the return type, but outside of that, this mostly looks good to me.

pkg/ottl/ottlfuncs/README.md Outdated Show resolved Hide resolved
pkg/ottl/ottlfuncs/func_hex.go Outdated Show resolved Hide resolved
@odubajDT odubajDT force-pushed the add-hex-function branch 2 times, most recently from 1bebaf2 to a503e5d Compare June 22, 2024 18:05
@odubajDT odubajDT marked this pull request as ready for review June 22, 2024 18:10
pkg/ottl/ottlfuncs/README.md Outdated Show resolved Hide resolved
pkg/ottl/ottlfuncs/README.md Outdated Show resolved Hide resolved
pkg/ottl/ottlfuncs/func_hex.go Outdated Show resolved Hide resolved
@evan-bradley
Copy link
Contributor

@TylerHelmuth please take a look.

@TylerHelmuth TylerHelmuth added the ready to merge Code review completed; ready to merge by maintainers label Jul 2, 2024
Signed-off-by: odubajDT <[email protected]>
Signed-off-by: odubajDT <[email protected]>
Signed-off-by: odubajDT <[email protected]>
Signed-off-by: odubajDT <[email protected]>
@evan-bradley evan-bradley merged commit 4e91206 into open-telemetry:main Jul 3, 2024
154 checks passed
@github-actions github-actions bot added this to the next release milestone Jul 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pkg/ottl ready to merge Code review completed; ready to merge by maintainers
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants