dev@grizzly.java.net

Re: Split entities (Controller, SelectorHandler...) and their configuration

From: charlie hunt <charlie.hunt_at_sun.com>
Date: Tue, 19 Feb 2008 12:29:30 -0600

I think another topic for Project Grizzly meeting. :-)

It might be useful to look at the peregrine contrib module and look at
the TransportConfiguration and TranportManager objects.

There's also a text file under the 'www' directory in that contrib
directory which has a brief explanation of those two objects along with
a couple example uses of them. There's also an example or two programs
that use these too.

In general, the TransportConfiguration allows one to specify the kind of
transport to construct. That TransportConfiguration is then given to
the TransportManager which knows how to take the TransportConfiguration
and turn it into an operational transport.

The other responsibility of the TransportManager is to manage the
lifecycle of transport, i.e. start, stop, pause and resume. I think
there's some similarities between the TransportManager and the existing
Controller.

I'm not necessarily suggesting that the TransportManager /
TransportConfiguration is "the" way to go. I think there may be
something there that may be useful.

charlie ...

Oleksiy Stashok wrote:
> Hello,
>
> recently we discussed with Jeanfrancois idea (proposed by Charlie?) of
> splitting Grizzly entities like Controller, SelectorHandlers and their
> configuration.
> So, basically we will remove lots of Controller/SelectorHandler fields
> getter and setter methods and move them to separate configuration object.
> As I understand example of Controller configuration will be:
>
> Was:
> Controller.setDefaultPipeline(pipeline)
>
> Will be:
> Controller.getConfiguration().setDefaultPipeline(pipeline)
>
> So this way we will need to create configuration objects for each
> entity we have: Controller, TCP/UDP/SSL SelectorHandler, TCP/UDP/SSL
> ConnectorHandler, SelectionKeyHandlers etc...
>
> May be someone has better idea how we can split those things,
> implement this better way - welcome :)
>
> Thanks.
>
> WBR,
> Alexey.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe_at_grizzly.dev.java.net
> For additional commands, e-mail: dev-help_at_grizzly.dev.java.net
>

-- 
Charlie Hunt
Java Performance Engineer
<http://java.sun.com/docs/performance/>