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

Jay Kreps commented on KAFKA-200:
---------------------------------

Hey John, can you validate that this setting actually works for large values 
(i.e. the value you set takes effect)? Values larger than 64k require special 
negotiation at socket creation time, so that can be trickier to make happen. 
This setting seems to be made on sockets already accepted so i wonder if it 
would take effect since the tcp window has already been negotiated at that 
point. Having been bruised by this before it is best to be careful.

Some docs on this are here: 
http://docs.oracle.com/javase/1.4.2/docs/api/java/net/Socket.html#setReceiveBufferSize%28int%29

Key point is that to get the buffer setting to take effect on the sockets the 
server accepts you actually need to set this on the ServerSocket not the 
accepted sockets. I think setting it on the socket that is accepted won't have 
any effect. But don't trust anything I say, best to try it out and see.
                
> Support configurable send / receive socket buffer size in server
> ----------------------------------------------------------------
>
>                 Key: KAFKA-200
>                 URL: https://issues.apache.org/jira/browse/KAFKA-200
>             Project: Kafka
>          Issue Type: Improvement
>          Components: core
>    Affects Versions: 0.7
>            Reporter: John Fung
>             Fix For: 0.8
>
>         Attachments: KAFKA-200.patch
>
>
> * Make the send / receive socket buffer size configurable in server.
> * KafkaConfig.scala already has the following existing variables to support 
> send / receive buffer:
>     socketSendBuffer
>     socketReceiveBuffer
> * The patch attached to this ticket will read the following existing settings 
> in <kafka>/config/server.properties and set the corresponding socket buffers
>     . . .
>     # The send buffer (SO_SNDBUF) used by the socket server
>     socket.send.buffer=1048576
>     # The receive buffer (SO_RCVBUF) used by the socket server
>     socket.receive.buffer=1048576

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to