feat(chunk): Add attachments to profile chunks#670
Draft
markushi wants to merge 1 commit into
Draft
Conversation
Profile chunks can now carry a generic `attachments` list referencing files stored in the object store, e.g. a raw perfetto trace kept alongside the processed chunk. Each entry has a `name`, an optional `content_type`, and a `stored_id` pointing at the stored object. Attachments are supported on sample v2 chunks only; they are dropped on legacy Android-format chunks. When merging chunks, the merged chunk collects the attachments of all merged chunks into its own list, skipping entries without a stored_id. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This was referenced Jun 14, 2026
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.
Profile chunks can now carry a generic
attachmentslist referencing files stored in the object store — e.g. a raw perfetto trace kept alongside the Sentry-processed chunk. Each entry has aname, an optionalcontent_type, and astored_idpointing at the stored object:The field is exposed on the chunk read path (
GetAttachments()) and serialized into the/chunksresponse. When chunks are merged, the merged chunk collects the attachments of all merged chunks into its ownattachmentslist (skipping entries without astored_id); the per-chunk and merged representations share the same shape.Attachments are a sample-v2-only concept: they are dropped on legacy Android-format chunks (no
versionfield), whereGetAttachments()returns nil. The field is omitted from serialized JSON when empty, so existing stored chunks and old payloads are unaffected.This is the Go read-path half of the cross-repo feature; the writer (sentry, via vroomrs) stamps the references onto the chunk, and the message contract lives in sentry-kafka-schemas. Companion vroomrs change: getsentry/vroomrs#92.
Note for reviewers: attachment entries on a merged chunk follow merge order and are not individually attributable to a source chunk — acceptable for the current use case.