Package net.hasor.rsf.runtime.client.netty

Examples of net.hasor.rsf.runtime.client.netty.ClientHandler


            b.option(ChannelOption.SO_KEEPALIVE, true);
            b.handler(new ChannelInitializer<SocketChannel>() {
                public void initChannel(SocketChannel ch) throws Exception {
                    ch.pipeline().addLast(//
                            new RSFCodec(),//
                            new ClientHandler(manager));
                }
            });
            //发起100万次调用.
            ChannelFuture f = b.connect(host, port).sync();
            {
View Full Code Here


        boot.channel(NioSocketChannel.class);
        boot.option(ChannelOption.SO_KEEPALIVE, true);
        final RsfContext rsfContext = this.rsfContext;
        boot.handler(new ChannelInitializer<SocketChannel>() {
            public void initChannel(SocketChannel ch) throws Exception {
                ch.pipeline().addLast(new RSFCodec(), new ClientHandler(rsfContext));
            }
        });
        ChannelFuture future = null;
        if (localAddress != null) {
            future = boot.connect(remoteAddress, localAddress);
View Full Code Here

TOP

Related Classes of net.hasor.rsf.runtime.client.netty.ClientHandler

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.