@Override
public void initChannel(SocketChannel ch) {
ChannelPipeline p = ch.pipeline();
if (sslCtx != null) {
p.addLast(sslCtx.newHandler(ch.alloc()));
}
p.addLast(new HttpRequestDecoder());
// Uncomment the following line if you don't want to handle HttpChunks.
p.addLast(new HttpObjectAggregator(65536));
p.addLast(new HttpResponseEncoder());
// Remove the following line if you don't want automatic content
// compression.
p.addLast(new HttpContentCompressor());
p.addLast(new ApiRequestParser());
}
ApiServerInitializer.java 文件源码
java
阅读 33
收藏 0
点赞 0
评论 0
项目:netty.book.kor
作者:
评论列表
文章目录