SNOW-3152214: add id generator for external telemetry#4082
Open
sfc-gh-yuwang wants to merge 9 commits intomainfrom
Open
SNOW-3152214: add id generator for external telemetry#4082sfc-gh-yuwang wants to merge 9 commits intomainfrom
sfc-gh-yuwang wants to merge 9 commits intomainfrom
Conversation
|
|
||
| else: | ||
|
|
||
| class ForkedSnowflakeTraceIdGenerator(ABC): |
There was a problem hiding this comment.
do we need this because if this is else we will not hit bit below where we are using ForkedSnowflakeTraceIdGenerator right?
Collaborator
Author
There was a problem hiding this comment.
yes, otherwise there would be compilation error
| trace_id = gen.generate_trace_id() | ||
|
|
||
| assert trace_id != trace.INVALID_TRACE_ID | ||
| assert trace_id.to_bytes(16, byteorder="big", signed=False) == ( |
There was a problem hiding this comment.
Can we also check first 4Bytes is timestamp in minute?
Collaborator
Author
There was a problem hiding this comment.
sure, will do
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Which Jira issue is this PR addressing? Make sure that there is an accompanying issue to your PR.
Fixes SNOW-3152214
Fill out the following pre-review checklist:
Please describe how your code solves the related issue.
This PR is meant to add span id generator that is needed for snowsight UI.
for this PR, a forked id generator is used, the reason is that:
currently snowflake-telemetry-python is pinning opentelemetry to 1.26.0, which is built with a very old protobuf version, while snowpark require using a newer protobuf version, which leads to conflicts.
We will switch to snowflake-telemetry-python implementation once they release a newer version