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(profiling): The priority thread metadata is optional #1392

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -13,6 +13,7 @@
- Fix a bug where unreal crash reports were dropped when metrics extraction is enabled. ([#1355](https://github.com/getsentry/relay/pull/1355))
- Extract user from metrics with EventUser's priority. ([#1363](https://github.com/getsentry/relay/pull/1363))
- Honor `SentryConfig.enabled` and don't init SDK at all if it is false. ([#1380](https://github.com/getsentry/relay/pull/1380))
- The priority thread metadata on profiles is now optional, do not fail the profile if it's not present. ([#1392](https://github.com/getsentry/relay/pull/1392))

**Internal**:

4 changes: 3 additions & 1 deletion relay-profiling/src/cocoa.rs
Original file line number Diff line number Diff line change
@@ -43,7 +43,9 @@ struct ThreadMetadata {

#[serde(default, skip_serializing_if = "String::is_empty")]
name: String,
priority: u32,

#[serde(skip_serializing_if = "Option::is_none")]
priority: Option<u32>,
}

#[derive(Debug, Serialize, Deserialize)]
32 changes: 8 additions & 24 deletions relay-profiling/tests/fixtures/profiles/cocoa.json
Original file line number Diff line number Diff line change
@@ -5880,33 +5880,17 @@
}
],
"thread_metadata": {
"24579": {
"priority": 31
},
"23299": {
"priority": 31
},
"4355": {
"priority": 31
},
"4615": {
"priority": 31
},
"7427": {
"priority": 31
},
"16643": {
"priority": 31
},
"26887": {
"priority": 31
},
"24579": {},
"23299": {},
"4355": {},
"4615": {},
"7427": {},
"16643": {},
"26887": {},
"259": {
"priority": 31
},
"21511": {
"priority": 31
}
"21511": {}
},
"queue_metadata": {
"0x000000016d987180": {