When I use multi-binding the server loops continuesly when I send a shutdown
request to the command port.
My idea was to create a Transport with different ServerConnection's, each
with a custom Processor. Like this:
for (X x: iterableSet)
{
String sAddress = x.getAddress();
int iPort = x.getPort();
Processor processor = x.getProcessor();
Connection serverConnection = transport.bind(sAddress, iPort);
serverConnection.setProcessor(processor);
}
When I sent a shutdown request (to one of the ServerConnections) an infinite
loop started. So I looked into the code and saw this in
TCPNIOServerConnection::registerAcceptedChannel:
Processor processor = transport.getProcessor();
When I replaced this with
Processor processor = this.getProcessor();
it worked fine. This also makes sense (to me at last ;-).
Is this correct (the fix), or should I use the framework in a different way?
In any case I think the infinite loop should be prevented.
--
View this message in context: http://www.nabble.com/Grizzly-2.0-M3-infinite-loop-using-multi-binding-tp23886746p23886746.html
Sent from the Grizzly - Users mailing list archive at Nabble.com.