[
https://issues.apache.org/jira/browse/IGNITE-25441?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17953603#comment-17953603
]
Pavel Tupitsyn commented on IGNITE-25441:
-----------------------------------------
Merged to main:
[a84f4c876f8287eb6b86e9bd1ab1a701e465df98|https://github.com/apache/ignite-3/commit/a84f4c876f8287eb6b86e9bd1ab1a701e465df98]
> Java thin 3.0: optimize Netty buffer usage in ClientInboundMessageHandler
> -------------------------------------------------------------------------
>
> Key: IGNITE-25441
> URL: https://issues.apache.org/jira/browse/IGNITE-25441
> Project: Ignite
> Issue Type: Improvement
> Components: thin clients ai3
> Reporter: Pavel Tupitsyn
> Assignee: Pavel Tupitsyn
> Priority: Major
> Labels: ignite-3
> Fix For: 3.1
>
> Time Spent: 0.5h
> Remaining Estimate: 0h
>
> Currently, we allocate response Netty buffers in
> *ClientInboundMessageHandler* too early - even before the processing has
> started. As a result, the buffer is out there doing nothing while a
> potentially long-running async operation is being processed. In case of many
> clients and many active requests, we'll have a lot of buffers allocated for
> no reason.
> Additionally, it is not always possible to ensure buffer release. Some
> operations may never complete due to bugs, node restarts, etc, causing buffer
> leaks.
> To improve the situation:
> * Release the request buffer as soon as reading is finished
> * Allocate the response buffer only when the result is ready to write
--
This message was sent by Atlassian Jira
(v8.20.10#820010)