Jeanfrancois Arcand wrote:
Salut,
the second issue we had is the concept of Controller. Alexey proposed
we get rid of this central notion and instead manipulate Transport
object, with no relationship between them. I do think having a central
object (Controller) to be able to set things like thread pool and
SelectorHandler is a good idea and makes users experience simple.
On that one, I'm +0 :-) but let discuss the pros and cons.
I think we need a central object for resource management.
I proposed calling this simply TransportManager. I think it needs to:
- Manage thread pool(s) (and this needs to be pluggable to handle
things like Sahoo's scheme for request prioritization).
- Manage ByteBuffer pools (like the scheme I proposed, in which the
SlabPool would naturally be found in the TransportManager).
- Act as a factory for transports.
What other centralized responsibilities should this class have?
Thanks,
Ken.