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 String converter #27867

Closed
4 tasks
TylerHelmuth opened this issue Oct 19, 2023 · 6 comments
Closed
4 tasks

[pkg/ottl] Add String converter #27867

TylerHelmuth opened this issue Oct 19, 2023 · 6 comments
Assignees
Labels
Contribfest enhancement New feature or request good first issue Good for newcomers pkg/ottl priority:p2 Medium

Comments

@TylerHelmuth
Copy link
Member

TylerHelmuth commented Oct 19, 2023

Component(s)

pkg/ottl

Is your feature request related to a problem? Please describe.

OTTL currently provides no way to convert from another type to a String.

Describe the solution you'd like

A new String converter function, similar to Int and Double that converts the input to a string.

The implementing PR should

  • Implement the function
  • Add new unit tests for the function
  • Add the function to pkg/ottl/ottlfuncs/functions.go
  • Update the README at pkg/ottl/ottlfuncs/README.md

Example PR for Double: #27457

@TylerHelmuth TylerHelmuth added enhancement New feature or request help wanted Extra attention is needed good first issue Good for newcomers priority:p2 Medium pkg/ottl Contribfest and removed help wanted Extra attention is needed good first issue Good for newcomers labels Oct 19, 2023
@nhAnik
Copy link

nhAnik commented Oct 21, 2023

Hi @TylerHelmuth , can I give it a try?

@TylerHelmuth TylerHelmuth added help wanted Extra attention is needed good first issue Good for newcomers labels Dec 13, 2023
@Palecha
Copy link

Palecha commented Dec 24, 2023

@TylerHelmuth I think this should be closed, I could see func_is_string.go and it's test function already been committed to repo.

@TylerHelmuth
Copy link
Member Author

@Palecha the IsString function is used to check if a path is a string or not. This issue is to create a function that converts the input into a string.

@victorhauvi
Copy link

Hey Tyler, I would love to be assigned this issue and work on this!

@TylerHelmuth TylerHelmuth removed the help wanted Extra attention is needed label Jan 15, 2024
Copy link
Contributor

This issue has been inactive for 60 days. It will be closed in 60 days if there is no activity. To ping code owners by adding a component label, see Adding Labels via Comments, or if you are unsure of which component this issue relates to, please ping @open-telemetry/collector-contrib-triagers. If this issue is still relevant, please ping the code owners or leave a comment explaining why it is still relevant. Otherwise, please close it.

Pinging code owners:

See Adding Labels via Comments if you do not have permissions to add labels yourself.

@github-actions github-actions bot added the Stale label Mar 15, 2024
TylerHelmuth added a commit that referenced this issue Mar 28, 2024
**Description:** 
- implemented func_string (string_converter)
- added new unit tests in `pkg/ottl/ottlfuncs/func_string_test.go`
- added function to `pkg/ottl/ottlfuncs/functions.go`
- updatet README.md at `pkg/ottl/ottlfuncs/README.md`
- added changelog

**Link to tracking Issue:** 
- #27867 

**Testing:** 

- added similar tests as in `pkg/ottl/ottlfuncs/func_double_test.go`


**Documentation:** <Describe the documentation added.>

---------

Co-authored-by: Tyler Helmuth <[email protected]>
@led0nk
Copy link
Contributor

led0nk commented Apr 1, 2024

should be solved by #31790

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Contribfest enhancement New feature or request good first issue Good for newcomers pkg/ottl priority:p2 Medium
Projects
None yet
Development

No branches or pull requests

5 participants