Skip to content

Remove ID Allocation Batch, instead JIT generating ID Allocations right before submitting other batch types#26779

Closed
markfields wants to merge 4 commits intomicrosoft:mainfrom
markfields:no-id-alloc-batch
Closed

Remove ID Allocation Batch, instead JIT generating ID Allocations right before submitting other batch types#26779
markfields wants to merge 4 commits intomicrosoft:mainfrom
markfields:no-id-alloc-batch

Conversation

@markfields
Copy link
Copy Markdown
Member

@markfields markfields commented Mar 19, 2026

PROTOTYPE / PROOF OF CONCEPT

This gets rid of ID Allocation Batches in the batch stream which makes detecting forked containers more robust and simple.

(Incidental rebirth of #24510 a year later)

…tions right before submitting other batch types.

This gets rid of ID Allocation Batches in the batch stream which makes detecting forked containers more robust and simple.
Per Claude:
The key insight from the e2e test failure: creating a standalone ID alloc batch during reconnect adds an unexpected entry to the
  pending queue, causing BatchInfoMismatch when the original (or forked) batches arrive. The flag approach avoids this by prepending
   the comprehensive range INTO the first replayed batch, preserving batch structure and CSN alignment for fork detection.
// Signal to the outbox that the next JIT ID allocation should use the comprehensive
// unfinalized range (instead of incremental). The range will be prepended to the
// first replayed batch, preserving batch structure for fork detection.
this.outbox.requestUnfinalizedIdRanges();
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This mechanism can go away if we merge #26784 first

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's in! 🎉

@markfields
Copy link
Copy Markdown
Member Author

Replaced by #26898

@markfields markfields closed this Apr 6, 2026
@markfields markfields deleted the no-id-alloc-batch branch April 6, 2026 17:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant