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

Melvin Wang commented on CASSANDRA-3005:
----------------------------------------

bq. poll() may be an unexpired entry, not the one peeked, if the sending thread 
switched queues and also took the front entry off in between the peek and the 
poll. In other words: you still have the same problem you had to start with, 
just more subtle.

The logic in run() guarantees that if the sending thread swaps, the queue 
pointed by 'producer' will be an empty one from which producer.poll() will 
yield 'null' and we will break from there w/o any operation.
                
> OutboundTcpConnection's sending queue grows unboundedly without any 
> backpressure logic
> --------------------------------------------------------------------------------------
>
>                 Key: CASSANDRA-3005
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-3005
>             Project: Cassandra
>          Issue Type: Improvement
>            Reporter: Melvin Wang
>            Assignee: Melvin Wang
>         Attachments: 3005-v3.txt, c3005-v2, c3005.patch
>
>
> OutboundTcpConnection's sending queue unconditionally queues up the request 
> and process them in sequence. Thinking about tagging the message coming in 
> with timestamp and drop them before actually sending it if the message stays 
> in the queue for too long, which is defined by the message's own time out 
> value.

--
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