feat(chunks): Accept android profiles in sample v2 format - #93
Merged
markushi merged 5 commits intoJul 9, 2026
Conversation
Member
Author
|
@sentry review |
markushi
commented
Jul 2, 2026
Relay will start emitting version "2.android-trace" for android profiles in the legacy android trace format, while android profiles in the sample v2 format carry version "2". Previously any profile with platform "android" was assumed to be in the legacy trace format, so sample v2 android chunks could not be processed. Dispatch profile chunk deserialization on the version instead of the platform: add ProfileChunk::from_json_vec_and_version and deprecate from_json_vec_and_platform, since the platform alone cannot distinguish the two formats. profile_chunk_from_json_str accepts a new optional version argument that takes precedence over platform. As a fallback to the legacy behavior in vroom, a missing or empty version is treated as the android trace format, and AndroidChunk now retains the version field so it survives compression round trips. Fixes JAVA-603 Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
markushi
force-pushed
the
markushintersteiner/java-603-update-vroomrs-to-accept-android-profiles-in-v2-format
branch
from
July 2, 2026 13:37
6c14764 to
d670a07
Compare
vroom maps any non-empty version to the sample format when reading chunks from storage, so persisting "2.android-trace" would break its read path. Drop the version field from AndroidChunk: unknown fields are ignored during deserialization, so ingest still accepts payloads carrying the new version, while stored chunks remain version-less and readable by both vroom and vroomrs. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This reverts commit 25cb74d.
0xadam-brown
reviewed
Jul 3, 2026
0xadam-brown
left a comment
Member
There was a problem hiding this comment.
Thanks a bunch for this!
A few comments; otherwise looking great 🙌
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Want reviews to match your repository better? Bugbot Learning can learn team-specific rules from PR activity. A team admin can enable Learning in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit b3201f1. Configure here.
manessaraj
approved these changes
Jul 8, 2026
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Dav1dde
approved these changes
Jul 9, 2026
markushi
deleted the
markushintersteiner/java-603-update-vroomrs-to-accept-android-profiles-in-v2-format
branch
July 9, 2026 07:13
markushi
added a commit
to getsentry/sentry
that referenced
this pull request
Jul 13, 2026
The Android SDK can now emit **sample v2** profiles in addition to the legacy android trace format. This wires the profiling pipeline to be able to process both. The whole pipeline previously always assumed that `platform="android"` provided a profile in the Android trace format - regardless if `version="2"` was set or not. `platform: "java"` profiles (aka profiles from backend services) are intentionally not deobfuscated for now, but support could be easily added. Also removes `get_data_category`, dead code since #81481. > [!NOTE] > `vroom` and `vroomrs` need to be updated as well to support the sample v2 Android format. > See getsentry/vroom#672 (was automatically deployed earlier this week) > and getsentry/vroomrs#93 (landed in `0.1.22`, which is bumped in this PR as well) ### Testing - Unit tests for the classifiers, frame conversion and the sample v2 merge/stack-remap (inline expansion + native passthrough). - Symbolicator integration tests for sample v2 (basic + inline) plus a full `process_profile_task` run. --------- Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
0xadam-brown
added a commit
to getsentry/sentry-java
that referenced
this pull request
Jul 24, 2026
Commit updates the platform used with ANR profiles from Java to Android so that we can properly bill ANR profiling under UI Profile Hours rather than Continuous Profile Hours. Depends on the updates made in [Relay #6183](getsentry/relay#6183), [getsentry #118849](getsentry/sentry#118849), [vroomrs #93](getsentry/vroomrs#93), and [vroom #672](getsentry/vroom#672).
Merged
12 tasks
0xadam-brown
added a commit
to getsentry/sentry-java
that referenced
this pull request
Jul 28, 2026
Commit updates the platform used with ANR profiles from Java to Android so that we can properly bill ANR profiling under UI Profile Hours rather than Continuous Profile Hours. Depends on the updates made in [Relay #6183](getsentry/relay#6183), [getsentry #118849](getsentry/sentry#118849), [vroomrs #93](getsentry/vroomrs#93), and [vroom #672](getsentry/vroom#672). # Conflicts: # CHANGELOG.md
0xadam-brown
added a commit
to getsentry/sentry-java
that referenced
this pull request
Jul 28, 2026
Commit updates the platform used with ANR profiles from Java to Android so that we can properly bill ANR profiling under UI Profile Hours rather than Continuous Profile Hours. Depends on the updates made in [Relay #6183](getsentry/relay#6183), [getsentry #118849](getsentry/sentry#118849), [vroomrs #93](getsentry/vroomrs#93), and [vroom #672](getsentry/vroom#672). # Conflicts: # CHANGELOG.md
0xadam-brown
added a commit
to getsentry/sentry-java
that referenced
this pull request
Jul 29, 2026
#5836) Commit updates the platform used with ANR profiles from Java to Android so that we can properly bill ANR profiling under UI Profile Hours rather than Continuous Profile Hours. Depends on the updates made in [Relay #6183](getsentry/relay#6183), [getsentry #118849](getsentry/sentry#118849), [vroomrs #93](getsentry/vroomrs#93), and [vroom #672](getsentry/vroom#672). Co-authored-by: Markus Hintersteiner <markus.hintersteiner@sentry.io>
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.

Dispatch profile chunk deserialization on the profile
versioninstead of theplatform.Previously any chunk with
platform: "android"was assumed to be in the legacy android trace format, so android profiles in the sample v2 format (version: "2", emitted by newer Android SDKs) could not be processed properly. Relay will soon start emittingversion: "2.android-trace"for chunks in the legacy trace format, which makes the version the reliable discriminator.Changes:
ProfileChunk::from_json_vec_**and_version**:"" | "2.android-trace"maps to the legacy android trace format, any other version to sample v2.ProfileChunk::from_json_vec_and_platformin favor of the new methodTransaction-based profiles (
Profile) are unaffected; the new version only applies to profile chunks.This unblocks sample v2 android support in the consuming service: getsentry/sentry#118849.
The
vroomservice changes are already merged / shipped: getsentry/vroom#672Fixes JAVA-603
🤖 Generated with Claude Code