@ Handler ( channels = NetworkChannel . class ) @ SuppressWarnings ( "PMD.DataflowAnomalyAnalysis" ) public void onConnected ( Connected event , TcpChannel netConnChannel ) throws InterruptedException , IOException { // Check if an app channel has been waiting for such a connection WebAppMsgChannel [ ] appChannel = { null } ; synchronized ( connecting ) { connecting . computeIfPresent ( event . remoteAddress ( ) , ( key , set ) -> { Iterator < WebAppMsgChannel > iter = set . iterator ( ) ; appChannel [ 0 ] = iter . next ( ) ; iter . remove ( ) ; return set . isEmpty ( ) ? null : set ; } ) ; } if ( appChannel [ 0 ] != null ) { appChannel [ 0 ] . connected ( netConnChannel ) ; } }
Called when the network connection is established . Triggers the frther processing of the initial request .