Java 类org.apache.http.nio.protocol.HttpAsyncRequestConsumer 实例源码

项目:OpsDev    文件:NHttpReverseProxy.java   
public HttpAsyncRequestConsumer<ProxyHttpExchange> processRequest(
        final HttpRequest request,
        final HttpContext context) {
    ProxyHttpExchange httpExchange = (ProxyHttpExchange) context.getAttribute("http-exchange");
    if (httpExchange == null) {
        httpExchange = new ProxyHttpExchange();
        context.setAttribute("http-exchange", httpExchange);
    }
    synchronized (httpExchange) {
        httpExchange.reset();
        String id = String.format("%08X", this.counter.getAndIncrement());
        httpExchange.setId(id);
        httpExchange.setTarget(this.target);
        return new ProxyRequestConsumer(httpExchange, this.executor, this.connPool);
    }
}
项目:oap    文件:NioHandlerAdapter.java   
@Override
public HttpAsyncRequestConsumer<HttpRequest> processRequest( final HttpRequest httpRequest,
                                                             final HttpContext httpContext )
   throws HttpException, IOException {

   return new BasicAsyncRequestConsumer();
}
项目:oap    文件:NioClasspathResourceHandler.java   
@Override
public HttpAsyncRequestConsumer<HttpRequest> processRequest( HttpRequest request,
    HttpContext context ) throws HttpException, IOException {
    return new BasicAsyncRequestConsumer();
}
项目:nio-benchmark    文件:SlowHelloRequestHandler.java   
@Override
public HttpAsyncRequestConsumer<HttpRequest> processRequest(final HttpRequest request, final HttpContext context) {
    // Buffer request content in memory for simplicity
    return new BasicAsyncRequestConsumer();
}
项目:nio-benchmark    文件:TestRequestHandler.java   
@Override
public HttpAsyncRequestConsumer<HttpRequest> processRequest(
        final HttpRequest request, final HttpContext context) {
    // Buffer request content in memory for simplicity
    return new BasicAsyncRequestConsumer();
}
项目:nio-benchmark    文件:HelloRequestHandler.java   
@Override
public HttpAsyncRequestConsumer<HttpRequest> processRequest(final HttpRequest request, final HttpContext context) {
    // Buffer request content in memory for simplicity
    return new BasicAsyncRequestConsumer();
}
项目:holico    文件:HttpStack.java   
@Override
public HttpAsyncRequestConsumer<HttpRequest> processRequest(HttpRequest httpRequest, HttpContext httpContext) throws HttpException, IOException {
    // Buffer request content in memory for simplicity
    return new BasicAsyncRequestConsumer();
}