use of io.netty.handler.codec.http.websocketx.WebSocket08FrameEncoder in project async-http-client by AsyncHttpClient.
the class ChannelManager method upgradePipelineForWebSockets.
public void upgradePipelineForWebSockets(ChannelPipeline pipeline) {
pipeline.addAfter(HTTP_CLIENT_CODEC, WS_ENCODER_HANDLER, new WebSocket08FrameEncoder(true));
pipeline.addBefore(AHC_WS_HANDLER, WS_DECODER_HANDLER, new WebSocket08FrameDecoder(false, false, config.getWebSocketMaxFrameSize()));
pipeline.addAfter(WS_DECODER_HANDLER, WS_FRAME_AGGREGATOR, new WebSocketFrameAggregator(config.getWebSocketMaxBufferSize()));
pipeline.remove(HTTP_CLIENT_CODEC);
}
Aggregations