Skip to content

Conversation

@Ian-Nara
Copy link
Contributor

No description provided.

@Ian-Nara Ian-Nara marked this pull request as ready for review December 11, 2025 01:52
…' into ian-UID2-6345-add-delta-writer-and-utility-classes
Base automatically changed from ian-UID2-6345-add-s3-utilities-send-corrupted-to-bucket to main December 12, 2025 02:12
@Ian-Nara Ian-Nara merged commit 4e150d0 into main Dec 12, 2025
4 checks passed
@Ian-Nara Ian-Nara deleted the ian-UID2-6345-add-delta-writer-and-utility-classes branch December 12, 2025 02:13
Comment on lines +105 to +111
private void ensureCapacity(int dataSize) {
if (buffer.capacity() < dataSize) {
int newCapacity = Integer.highestOneBit(dataSize) << 1;
LOGGER.info("expanding buffer size: current {}, need {}, new {}", buffer.capacity(), dataSize, newCapacity);
this.buffer = ByteBuffer.allocate(newCapacity).order(ByteOrder.LITTLE_ENDIAN);
}
}
Copy link
Contributor

Choose a reason for hiding this comment

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

This method is always called with dataSize = OptOutConst.EntrySize. Why don't we remove this method and the ctor's bufferSize param, and initialize buffer with the required capacity?

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.

4 participants