Skip to content

ref(spans): split load_segment_data into helper steps#116136

Merged
lvthanh03 merged 4 commits into
masterfrom
tony/spans-refactor-flush
May 26, 2026
Merged

ref(spans): split load_segment_data into helper steps#116136
lvthanh03 merged 4 commits into
masterfrom
tony/spans-refactor-flush

Conversation

@lvthanh03
Copy link
Copy Markdown
Member

Refactors _load_segment_data into an orchestration function with unit testable helpers:

  • load payload keys for each segment
  • scan/decompress payload batches from those payload keys, return loaded payloads and cleanup keys as LoadedSegmentData

Also updates the cumulative flusher logger to accept loaded segment payloads and build its own FlusherLogEntry values, removing the bookkeeping from flush_segments.

Segment-loss accounting is also split into _record_segment_loss_metrics, so _load_segment_data only loads data.

@lvthanh03 lvthanh03 requested review from a team as code owners May 25, 2026 17:13
@github-actions github-actions Bot added the Scope: Backend Automatically applied to PRs that change backend components label May 25, 2026
@lvthanh03 lvthanh03 merged commit 1a2d800 into master May 26, 2026
62 checks passed
@lvthanh03 lvthanh03 deleted the tony/spans-refactor-flush branch May 26, 2026 14:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Scope: Backend Automatically applied to PRs that change backend components

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants