Gargi-jais11 opened a new pull request, #9166:
URL: https://github.com/apache/ozone/pull/9166

   ## What changes were proposed in this pull request?
   Currently RpcClient has a ElasticByteBufferPool to reuse buffers during EC 
data read and write. ElasticByteBufferPool can save the time of buffer 
allocation. While this Pool doesn't have a upper limit, so in s3g case, a long 
lived RpcClient will accumulate all buffers allocated through this pool, which 
lead to high memory pressure of s3g.
   
   **Solution:**
   Create a new class implementing `ByteBufferPool` which will be a bounded 
version of `ElasticByteBufferPool` that limits the total size of buffers that 
can be cached in the pool.
   To control the size of this pool added a new configuration :
   ```
   public static final String OZONE_CLIENT_ELASTIC_BYTE_BUFFER_POOL_MAX_SIZE_GB 
=
         "ozone.client.elastic.byte.buffer.pool.max.size.gb";
   public static final String 
OZONE_CLIENT_ELASTIC_BYTE_BUFFER_POOL_MAX_SIZE_GB_DEFAULT = "16GB";
   
   ```
   In `RPCClient` use `BoundedElasticByteBufferPool` instead of 
`ElasticByteBufferPool`.
   
   ## What is the link to the Apache JIRA
   
   https://issues.apache.org/jira/browse/HDDS-13400
   
   ## How was this patch tested?
   
   Passed Existing Tests and green CI.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to