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

span id to hex #2062

Merged
merged 7 commits into from
Feb 22, 2023
Merged

span id to hex #2062

merged 7 commits into from
Feb 22, 2023

Conversation

ie-pham
Copy link
Contributor

@ie-pham ie-pham commented Feb 3, 2023

What this PR does: stop removing leading zeroes in span ids

Which issue(s) this PR fixes:
Fixes #2060

Checklist

  • Tests updated
  • Documentation added
  • CHANGELOG.md updated - the order of entries should be [CHANGE], [FEATURE], [ENHANCEMENT], [BUGFIX]

@ie-pham ie-pham requested a review from joe-elliott February 21, 2023 17:48
Copy link
Member

@joe-elliott joe-elliott left a comment

Choose a reason for hiding this comment

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

This looks good. One last thing! Add a changelog entry then we'll merge and backport to 2.0.1

@ie-pham
Copy link
Contributor Author

ie-pham commented Feb 21, 2023

@joe-elliott One last question, extra logic would have to be added to this I believe but what happens if the span id has leading zeroes and it is longer than 16 characters? Still no trimming?

@joe-elliott
Copy link
Member

@joe-elliott One last question, extra logic would have to be added to this I believe but what happens if the span id has leading zeroes and it is longer than 16 characters? Still no trimming?

since we're in "shouldn't happen" territory i'm fine with anything that:

  • doesn't panic
  • makes decent sense
  • doesn't overcomplicate the code

Copy link
Member

@joe-elliott joe-elliott left a comment

Choose a reason for hiding this comment

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

looks good!

@joe-elliott joe-elliott added type/bug Something isn't working backport release-v2.0 labels Feb 22, 2023
@joe-elliott joe-elliott merged commit 2d50f21 into grafana:main Feb 22, 2023
@github-actions
Copy link
Contributor

The backport to release-v2.0 failed:

The process '/usr/bin/git' failed with exit code 1

To backport manually, run these commands in your terminal:

# Fetch latest updates from GitHub
git fetch
# Create a new branch
git switch --create backport-2062-to-release-v2.0 origin/release-v2.0
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x 2d50f21918c81a433e62b6f9b759ca7b98ed7482
# Push it to GitHub
git push --set-upstream origin backport-2062-to-release-v2.0
git switch main
# Remove the local backport branch
git branch -D backport-2062-to-release-v2.0

Then, create a pull request where the base branch is release-v2.0 and the compare/head branch is backport-2062-to-release-v2.0.

joe-elliott pushed a commit that referenced this pull request Feb 23, 2023
* span id to hex

* logic

* simplify

* fmt

* update test

* what is logic

* changelog

(cherry picked from commit 2d50f21)
joe-elliott added a commit that referenced this pull request Feb 23, 2023
* span id to hex

* logic

* simplify

* fmt

* update test

* what is logic

* changelog

(cherry picked from commit 2d50f21)

Co-authored-by: Jennie Pham <[email protected]>
@ie-pham ie-pham deleted the jpham/2060 branch March 17, 2023 17:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Stop trimming leading 0s on span ids
2 participants