Class HttpServerExpectContinueHandler

All Implemented Interfaces:
ChannelHandler, ChannelInboundHandler

public class HttpServerExpectContinueHandler extends ChannelInboundHandlerAdapter
Sends a 100 CONTINUE HttpResponse to HttpRequests which contain a 'expect: 100-continue' header. It should only be used for applications which do not install the HttpObjectAggregator.

By default it accepts all expectations.

Since HttpServerExpectContinueHandler expects HttpRequests it should be added after HttpServerCodec but before any other handlers that might send a HttpResponse.

  ChannelPipeline p = ...;
  ...
  p.addLast("serverCodec", new HttpServerCodec());
  p.addLast("respondExpectContinue", new HttpServerExpectContinueHandler());
  ...
  p.addLast("handler", new HttpRequestHandler());