Can you share ChannelFactory / worker threads in a p2p app?

Thingfish jannick at ovja.dk
Sun Nov 22 18:42:47 EST 2009


Hi

I'm currently in the process of coding a peer 2 peer app on top of Netty. By
definition each peer acts as both a server and a client, which means that I
currently make use of both the ClientBootstrap and ServerBootstrap   to
support "connection setup" in both directions. Once established "incomming"
and "outgoing" connections are indistinct able, and for this reason they
share the same pipeline factory. 

My question is, if its possible to also have them share the same worker
threads and selectors? Currently the use of seperate NioClient and NioServer
SocketChannelFactories means, that two disjoint sets of worker threads and
I/O resources are created. As both these worker pools deliver the exact same
service, it would be more efficient to avoid the extra threads.

-- 
View this message in context: http://n2.nabble.com/Can-you-share-ChannelFactory-worker-threads-in-a-p2p-app-tp4048241p4048241.html
Sent from the Netty User Group mailing list archive at Nabble.com.


More information about the netty-users mailing list