[ 
https://issues.apache.org/jira/browse/KAFKA-8154?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16810459#comment-16810459
 ] 

Gordon commented on KAFKA-8154:
-------------------------------

Thank you.

That being the case, the BUFFER_UNDERFLOW error that Rajesh posted has a 
different underlying cause.  In that case, one unwrap operation results in 
BUFFER_OVERFLOW, but due to their change, the error isn't handled.  The outer 
loop will terminate because dst is full.  On the next call to read(), the 
unwrap operation will have left data in the network buffer because the 
application buffer was full previously, and there will no longer a full buffer 
worth of space for the readFromSocketChannel operation.  That's when the code 
will raise the BUFFER_UNDERFLOW error.

This condition has nothing to do with buffer size mismatches.

> Buffer Overflow exceptions between brokers and with clients
> -----------------------------------------------------------
>
>                 Key: KAFKA-8154
>                 URL: https://issues.apache.org/jira/browse/KAFKA-8154
>             Project: Kafka
>          Issue Type: Bug
>          Components: clients
>    Affects Versions: 2.1.0
>            Reporter: Rajesh Nataraja
>            Priority: Major
>         Attachments: server.properties.txt
>
>
> https://github.com/apache/kafka/pull/6495
> https://github.com/apache/kafka/pull/5785



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to