//
// if timeout is throw then chek if is running and accept again
continue;
} catch(SocketException e) {
state = STATE_ERROR;
lastException = new TuboConsumerLoaderException("Error on TCP",e);
break;
} catch(IOException e) {
state = STATE_ERROR;
lastException = new TuboConsumerLoaderException("IO Error",e);
break;
} catch(SecurityException e) {
state = STATE_ERROR;
lastException = new TuboConsumerLoaderException("Security Error",e);
break;
} catch(IllegalBlockingModeException e) {
state = STATE_ERROR;
lastException = new TuboConsumerLoaderException("Blocking Mode Error",e);
break;
}
if (isRunning()) {
//
// get a consumer for this socket (client)
ServerSocketConsumer consumer = null;
try {
consumer = (ServerSocketConsumer)manager.getConsumer();
} catch (TuboResourceException e) {
state = STATE_ERROR;
lastException = new TuboConsumerLoaderException("Error getting consumer",e);
break;
}
//
// create a process thread for this socket
ServerSocketConsumerWorker consumerWorker = new ServerSocketConsumerWorker(socket,consumer,manager);