You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by "Dave Revell (JIRA)" <ji...@apache.org> on 2010/10/25 22:32:22 UTC

[jira] Created: (CASSANDRA-1663) Allow configuration of thrift socket backlog

Allow configuration of thrift socket backlog
--------------------------------------------

                 Key: CASSANDRA-1663
                 URL: https://issues.apache.org/jira/browse/CASSANDRA-1663
             Project: Cassandra
          Issue Type: Improvement
            Reporter: Dave Revell
            Priority: Minor


It would be nice to allow configuration of the Thrift server socket's listen backlog size. The current limit is sometimes reached on my servers. I believe Thrift uses the ServerSocket default, which is 50 pending sockets.

This might be able to merge with CASSANDRA-1405, which also involves thrift socket changes.

When connection volume is high, Cassandra fails to accept some connections because the socket listen backlog is full. This happens to about 0.1% of connections in my case. System load and IO are very low, so this does not seem to be a capacity problem.

Helpful tip: on my Centos 5 box with kernel 2.6.18, the kernel exposes the number of socket listen queue overflows in netstat. You can do e.g.:

{noformat}
# netstat -s | grep 'listen queue'
    123 times the listen queue of a socket overflowed
{noformat}


-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] [Resolved] (CASSANDRA-1663) Allow configuration of thrift socket backlog

Posted by "Jonathan Ellis (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CASSANDRA-1663?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jonathan Ellis resolved CASSANDRA-1663.
---------------------------------------

    Resolution: Later

> Allow configuration of thrift socket backlog
> --------------------------------------------
>
>                 Key: CASSANDRA-1663
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-1663
>             Project: Cassandra
>          Issue Type: Improvement
>            Reporter: Dave Revell
>            Priority: Minor
>
> It would be nice to allow configuration of the Thrift server socket's listen backlog size. The current limit is sometimes reached on my servers. I believe Thrift uses the ServerSocket default, which is 50 pending sockets.
> This might be able to merge with CASSANDRA-1405, which also involves thrift socket changes.
> When connection volume is high, Cassandra fails to accept some connections because the socket listen backlog is full. This happens to about 0.1% of connections in my case. System load and IO are very low, so this does not seem to be a capacity problem.
> Helpful tip: on my Centos 5 box with kernel 2.6.18, the kernel exposes the number of socket listen queue overflows in netstat. You can do e.g.:
> {noformat}
> # netstat -s | grep 'listen queue'
>     123 times the listen queue of a socket overflowed
> {noformat}

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] Commented: (CASSANDRA-1663) Allow configuration of thrift socket backlog

Posted by "Jonathan Ellis (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CASSANDRA-1663?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12924725#action_12924725 ] 

Jonathan Ellis commented on CASSANDRA-1663:
-------------------------------------------

We can add a configuration setting, but isn't the right solution to pool connections client-side?

> Allow configuration of thrift socket backlog
> --------------------------------------------
>
>                 Key: CASSANDRA-1663
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-1663
>             Project: Cassandra
>          Issue Type: Improvement
>            Reporter: Dave Revell
>            Priority: Minor
>
> It would be nice to allow configuration of the Thrift server socket's listen backlog size. The current limit is sometimes reached on my servers. I believe Thrift uses the ServerSocket default, which is 50 pending sockets.
> This might be able to merge with CASSANDRA-1405, which also involves thrift socket changes.
> When connection volume is high, Cassandra fails to accept some connections because the socket listen backlog is full. This happens to about 0.1% of connections in my case. System load and IO are very low, so this does not seem to be a capacity problem.
> Helpful tip: on my Centos 5 box with kernel 2.6.18, the kernel exposes the number of socket listen queue overflows in netstat. You can do e.g.:
> {noformat}
> # netstat -s | grep 'listen queue'
>     123 times the listen queue of a socket overflowed
> {noformat}

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (CASSANDRA-1663) Allow configuration of thrift socket backlog

Posted by "Dave Revell (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CASSANDRA-1663?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12924733#action_12924733 ] 

Dave Revell commented on CASSANDRA-1663:
----------------------------------------

I agree that client-side pooling is the best way to solve the problem in my case, and that's what I'll be using.

However, this is an option that perhaps should exist anyway. Many popular servers allow this value to be configured, especially those that are designed for high concurrency and high capacity. Some people might prefer not to use connection pooling; writing a correct shared socket pool isn't too hard but is not trivial. Also, people who deploy a service without connection pooling and scale up may see this as an unexpected scaling limit.

Not very strong arguments, I know, but flexibility seems better than inflexibility.

> Allow configuration of thrift socket backlog
> --------------------------------------------
>
>                 Key: CASSANDRA-1663
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-1663
>             Project: Cassandra
>          Issue Type: Improvement
>            Reporter: Dave Revell
>            Priority: Minor
>
> It would be nice to allow configuration of the Thrift server socket's listen backlog size. The current limit is sometimes reached on my servers. I believe Thrift uses the ServerSocket default, which is 50 pending sockets.
> This might be able to merge with CASSANDRA-1405, which also involves thrift socket changes.
> When connection volume is high, Cassandra fails to accept some connections because the socket listen backlog is full. This happens to about 0.1% of connections in my case. System load and IO are very low, so this does not seem to be a capacity problem.
> Helpful tip: on my Centos 5 box with kernel 2.6.18, the kernel exposes the number of socket listen queue overflows in netstat. You can do e.g.:
> {noformat}
> # netstat -s | grep 'listen queue'
>     123 times the listen queue of a socket overflowed
> {noformat}

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.