@ Override public StateConnection service ( ) { try { StateConnection nextState = _state . service ( this ) ; //return StateConnection.CLOSE; return nextState ; /* if (_invocation == null && getRequestHttp().parseInvocation()) { if (_invocation == null) { return NextState.CLOSE; } return _invocation.service(this, getResponse()); } else if (_upgrade != null) { return _upgrade.service(); } else if (_invocation != null) { return _invocation.service(this); } else { return StateConnection.CLOSE; } */ } catch ( Throwable e ) { log . warning ( e . toString ( ) ) ; log . log ( Level . FINER , e . toString ( ) , e ) ; //e.printStackTrace(); toClose ( ) ; return StateConnection . CLOSE_READ_A ; } }
Service is the main call when data is available from the socket .