-
Type:
Bug
-
Resolution: Unresolved
-
Priority:
Unknown
-
None
-
Affects Version/s: 5.6.2
-
Component/s: Wire Protocol
-
None
Summary
When using MongoDB Java Driver version 5.6.2 in combination with JDK 25.0.1 and Netty 4.2.9 (as provided by Spring Boot 4.0.1), a ByteBuf leak is reported at runtime:
“LEAK: ByteBuf.release() was not called before it’s garbage-collected”
The same application setup does not show this issue when using MongoDB Java Driver version 5.5.2. This suggests a regression introduced between driver versions 5.5.2 and 5.6.2 related to Netty buffer lifecycle management.
The corresponding Netty leak log for a single leak is attached to this issue.
Expected Result
No ByteBuf leak warnings should be reported.
Control Test
Downgrading only the MongoDB Java Driver to version 5.5.2 while keeping all other components identical removes the leak warning completely.