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

feat(profiling): Add support for Profiling #479

Merged
merged 12 commits into from
Jul 1, 2022
Prev Previous commit
Next Next commit
fix linting
  • Loading branch information
viglia committed Jun 27, 2022
commit 552e9363ba58ca9f08c435f5a699fd76e45ab08b
2 changes: 1 addition & 1 deletion sentry-core/src/client.rs
Original file line number Diff line number Diff line change
Expand Up @@ -216,7 +216,7 @@ impl Client {
}

if !self.sample_should_send(self.options.sample_rate) {
return None;
None
} else {
Some(event)
}
Expand Down
4 changes: 2 additions & 2 deletions sentry-types/src/protocol/profile.rs
Original file line number Diff line number Diff line change
Expand Up @@ -98,13 +98,13 @@ impl Profile {
"{}",
serde_json::to_string(&ProfileItemHeader {
content_type: "application/json".to_string(),
file_name: format!("{}.trace", self.trace_id).to_string(),
file_name: format!("{}.trace", self.trace_id),
typez: "profile".to_string(),
length: serialized_profile.len(),
})?
)?;

writer.write_all(&serialized_profile.as_bytes())?;
writer.write_all(serialized_profile.as_bytes())?;
Ok(())
}
}