[
https://issues.apache.org/jira/browse/THRIFT-1167?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Vijay updated THRIFT-1167:
--------------------------
Attachment: TSHSHAServer-Patch-MultiThreaded_v3.patch
Hi Steve and Bryan,
I think OS does a good job in load balancing and do we really need to implement
our own LB?
I implemented something similar for cassandra... Plz see the below result...
I can modify the existing codebase and provide a more integrated patch if you
think this approach makes sense.
// total writes into cassandra (*2 will provide you the approx number of read
and write into the socket).
lgmacd-vparth:Cass vparthasarathy$ grep "insert writing"
/var/log/cassandra/system.log |wc -l
1103
// total
lgmacd-vparth:Cass vparthasarathy$ grep "eciving packets"
/var/log/cassandra/system.log|wc -l
2221
// split per thread.
lgmacd-vparth:Cass vparthasarathy$ grep "eciving packets"
/var/log/cassandra/system.log|awk '{print $2}'|sort |uniq -c
137 [Selector-Thread-0]
139 [Selector-Thread-10]
138 [Selector-Thread-11]
139 [Selector-Thread-12]
139 [Selector-Thread-13]
139 [Selector-Thread-14]
139 [Selector-Thread-15]
139 [Selector-Thread-1]
139 [Selector-Thread-2]
139 [Selector-Thread-3]
139 [Selector-Thread-4]
139 [Selector-Thread-5]
139 [Selector-Thread-6]
139 [Selector-Thread-7]
139 [Selector-Thread-8]
139 [Selector-Thread-9]
> Java nonblocking server with more than one thread for select and handling IO
> ----------------------------------------------------------------------------
>
> Key: THRIFT-1167
> URL: https://issues.apache.org/jira/browse/THRIFT-1167
> Project: Thrift
> Issue Type: New Feature
> Components: Java - Library
> Reporter: Steve Jiang
> Assignee: Bryan Duxbury
> Attachments: TSHSHAServer-Patch-MultiThreaded_v3.patch,
> threadedselectorthrift3.diff
>
>
> I've used the HsHa server model to write a server that uses a thread for
> accept and a separate, configurable number of Selector threads to handle IO.
> I'd like to contribute this back to Thrift.
> For apps that are RPC-heavy and require little computation from the executor
> pool running on multi-core architectures, this server allows gets throughput
> as IO is not limited by one CPU.
> Please take a look at the attached patch.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira