Skip to content

fix: default LittleEndianByteBufAllocator to pooled allocator and release row slices on error - #448

Merged
oshai merged 1 commit into
masterfrom
fix/issue-435-pooled-allocator-row-leak
Nov 9, 2026
Merged

oshai merged 1 commit into
masterfrom
fix/issue-435-pooled-allocator-row-leak

Conversation

@oshai

@oshai oshai commented Nov 9, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Default LittleEndianByteBufAllocator to PooledByteBufAllocator.DEFAULT (accepting any ByteBufAllocator and delegating isDirectBufferPooled) and wire LittleEndianByteBufAllocator(configuration.allocator) in MySQLConnectionHandler so direct buffers (such as SslHandler / netty-tcnative) use pooled allocation rather than unpooled direct memory.
  • Release all retained ResultSetRowMessage column ByteBuf slices in an outer finally block in MySQLConnectionHandler so a decode exception on an earlier column cannot leak remaining column slices.

Fixes #435

@oshai
oshai merged commit d429902 into master Nov 9, 2026
2 checks passed
@oshai
oshai deleted the fix/issue-435-pooled-allocator-row-leak branch November 9, 2026 21:04
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.

LittleEndianByteBufAllocator uses UnpooledByteBufAllocator is not optimal and potentially causing OOM error

1 participant