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

fix(protocol): Flatten Linux distribution fields into os.context #4292

Merged
merged 2 commits into from
Nov 28, 2024

Conversation

JoshuaMoelans
Copy link
Member

@JoshuaMoelans JoshuaMoelans commented Nov 25, 2024

(continuation of #3443 )

To make these fields searchable, we had to change from a nested to a flattened approach. This is provided in sentry-native (relevant PR).

The update is also tracked on the docs side: getsentry/sentry-docs#11936

@JoshuaMoelans JoshuaMoelans marked this pull request as ready for review November 27, 2024 09:37
@JoshuaMoelans JoshuaMoelans requested a review from a team as a code owner November 27, 2024 09:37
@JoshuaMoelans
Copy link
Member Author

I'm not sure if this is a skip-changelog kind of situation; the previous (non-flattened) implementation is listed as a feature under 24.4.1 , so maybe this update should be labelled as a fix/internal?

Copy link
Member

@jjbayer jjbayer left a comment

Choose a reason for hiding this comment

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

Why does it need to be flattened to become searchable? Could we fix this on the storage end instead of changing the schema?

@JoshuaMoelans
Copy link
Member Author

@jjbayer snuba cannot handle the nesting we had before (and the team apparently was reluctant to add this feature, hence this PR was closed without merging). They suggested to flatten our 3-layered context values back to 2 layers.

@jjbayer
Copy link
Member

jjbayer commented Nov 27, 2024

snuba cannot handle the nesting we had before (and the team apparently was reluctant to add this feature, hence this PR was closed without merging). They suggested to flatten our 3-layered context values back to 2 layers.

@JoshuaMoelans have SDKs already been sending the nested format? In that case, we need to still accept the nested format and normalize it into the flat format.

@JoshuaMoelans
Copy link
Member Author

@jjbayer no, since we never merged & released the sentry-native PR we have not been sending these nested format events.

@jjbayer
Copy link
Member

jjbayer commented Nov 27, 2024

@jjbayer no, since we never merged & released the sentry-native PR we have not been sending these nested format events.

In that case I'm running out of objections 😄. Please add a **Breaking Changes**: entry to both CHANGELOG.md and py/CHANGELOG.md because this is technically a breaking change to the protocol, even if none of our own SDKs was using it yet

@JoshuaMoelans JoshuaMoelans changed the title fix(protocol): Flatten Linux distribution into os context fix(protocol): Flatten Linux distribution fields into os.context Nov 27, 2024
@JoshuaMoelans JoshuaMoelans merged commit c3a0efd into master Nov 28, 2024
24 checks passed
@JoshuaMoelans JoshuaMoelans deleted the joshua/fix/flatten-distribution-event-payload branch November 28, 2024 09:26
JoshuaMoelans added a commit to getsentry/sentry that referenced this pull request Nov 28, 2024
<!-- Describe your PR here. -->
update to #69865
To search the distribution fields, we cannot have them in a hierarchy
`os.distribution.name`, we instead need them flattened to
`os.distribution_name`

This is part of reworking the following native-SDK PR:
getsentry/sentry-native#963

The update is also tracked on the docs side:
getsentry/sentry-docs#11936
And on Relay: getsentry/relay#4292
andrewshie-sentry pushed a commit to getsentry/sentry that referenced this pull request Dec 2, 2024
<!-- Describe your PR here. -->
update to #69865
To search the distribution fields, we cannot have them in a hierarchy
`os.distribution.name`, we instead need them flattened to
`os.distribution_name`

This is part of reworking the following native-SDK PR:
getsentry/sentry-native#963

The update is also tracked on the docs side:
getsentry/sentry-docs#11936
And on Relay: getsentry/relay#4292
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants