Skip to content

Conversation

@afarber
Copy link
Contributor

@afarber afarber commented Dec 20, 2025

Fixes #13513

Refactored MemoryEndPointPipe to use RetainableByteBuffer.DynamicCapacity instead of allocating ByteBuffers directly.

Changes:

  • Replace Deque<ByteBuffer> with Deque<RetainableByteBuffer>
  • Each flush() creates a DynamicCapacity buffer via append() and adds it to the deque
  • fillInto() reads from the deque using get(), releasing buffers when fully consumed
  • Preserve existing EOF sentinel pattern for proper data/EOF ordering
  • Add edge case tests for EOF handling, close behavior, and capacity limits
  • Add notes to migration docs

@sbordet sbordet self-requested a review January 5, 2026 17:24
@sbordet sbordet moved this to 👀 In review in Jetty 12.1.7 Jan 5, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: 👀 In review

Development

Successfully merging this pull request may close these issues.

Make MemoryEndPoint use RBB.DynamicCapacity

1 participant