@@ -277,8 +277,8 @@ void configureNetty() {
277
277
/* @Override */
278
278
public ChannelPipeline getPipeline () throws Exception {
279
279
ChannelPipeline pipeline = pipeline ();
280
- pipeline .addLast ("ws -decoder" , new HttpResponseDecoder ());
281
- pipeline .addLast ("ws -encoder" , new HttpRequestEncoder ());
280
+ pipeline .addLast ("http -decoder" , new HttpResponseDecoder ());
281
+ pipeline .addLast ("http -encoder" , new HttpRequestEncoder ());
282
282
pipeline .addLast ("httpProcessor" , NettyAsyncHttpProvider .this );
283
283
return pipeline ;
284
284
}
@@ -354,8 +354,8 @@ public ChannelPipeline getPipeline() throws Exception {
354
354
abort (cl .future (), ex );
355
355
}
356
356
357
- pipeline .addLast ("ws -decoder" , new HttpResponseDecoder ());
358
- pipeline .addLast ("ws -encoder" , new HttpRequestEncoder ());
357
+ pipeline .addLast ("http -decoder" , new HttpResponseDecoder ());
358
+ pipeline .addLast ("http -encoder" , new HttpRequestEncoder ());
359
359
pipeline .addLast ("httpProcessor" , NettyAsyncHttpProvider .this );
360
360
361
361
return pipeline ;
@@ -2390,8 +2390,8 @@ public void handle(ChannelHandlerContext ctx, MessageEvent e) throws Exception {
2390
2390
throw new IOException (String .format ("Invalid challenge. Actual: %s. Expected: %s" , accept , key ));
2391
2391
}
2392
2392
2393
- ctx .getPipeline ().replace ("ws-decoder" , "ws-decoder" , new WebSocket08FrameDecoder (false , false ));
2394
- ctx .getPipeline ().replace ("ws -encoder" , "ws-encoder" , new WebSocket08FrameEncoder (true ));
2393
+ ctx .getPipeline ().get ( HttpResponseDecoder . class ). replace ("ws-decoder" , new WebSocket08FrameDecoder (false , false ));
2394
+ ctx .getPipeline ().replace ("http -encoder" , "ws-encoder" , new WebSocket08FrameEncoder (true ));
2395
2395
if (h .onHeadersReceived (responseHeaders ) == STATE .CONTINUE ) {
2396
2396
h .onSuccess (new NettyWebSocket (ctx .getChannel ()));
2397
2397
}
0 commit comments