try {
PipeImpl requestPipe = new PipeImpl(); // the pipe used to process the request
PipeImpl responsePipe = new PipeImpl(); // the pipe used to process the response
context.setAttribute(REQUEST_SINK_CHANNEL, requestPipe.sink());
context.setAttribute(RESPONSE_SOURCE_CHANNEL, responsePipe.source());
// create the default response to this request
ProtocolVersion httpVersion = request.getRequestLine().getProtocolVersion();
HttpResponse response = responseFactory.newHttpResponse(
httpVersion, HttpStatus.SC_OK, context);