use of com.ctrip.xpipe.redis.keeper.simple.latency.netty.ReceiveMessageHandler in project x-pipe by ctripcorp.
the class PsyncLatencyTest method startGetLatency.
private void startGetLatency() {
EventLoopGroup eventLoopGroup = new NioEventLoopGroup();
Bootstrap b = new Bootstrap();
b.group(eventLoopGroup).channel(NioSocketChannel.class).option(ChannelOption.TCP_NODELAY, true).handler(new ChannelInitializer<SocketChannel>() {
@Override
public void initChannel(SocketChannel ch) throws Exception {
ChannelPipeline p = ch.pipeline();
p.addLast(new LoggingHandler(LogLevel.DEBUG));
p.addLast(new NettySimpleMessageHandler());
p.addLast(new ReceiveMessageHandler(runId, offset));
}
});
b.connect(dest);
}
Aggregations