@Override
    public void channelOpen(final ChannelHandlerContext ctx, final ChannelStateEvent e)
            throws Exception {
		try {
	        // make the proxy connection
			ensureTargetConnection ( e.getChannel(), false, null );
		} catch (Exception ex) {
			// target connection failed, so close the client connection
			e.getChannel().close();
			ex.printStackTrace();
		}
    }
@Override
    public void channelOpen(final ChannelHandlerContext ctx, final ChannelStateEvent e)
            throws Exception {
		try {
	        
			ensureTargetConnection ( e.getChannel(), false, null );
		} catch (Exception ex) {
			
			e.getChannel().close();
			ex.printStackTrace();
		}
    }
@ Override public void channelOpen ( final ChannelHandlerContext ctx , final ChannelStateEvent e ) throws Exception { try { // make the proxy connection
 ensureTargetConnection ( e . getChannel ( ) , false , null ) ; } catch ( Exception ex ) { // target connection failed, so close the client connection
 e . getChannel ( ) . close ( ) ; ex . printStackTrace ( ) ; } }
The client won't send any message so connect directly on channel open
The client won t send any message so connect directly on channel open