Return-Path: X-Original-To: apmail-hc-commits-archive@www.apache.org Delivered-To: apmail-hc-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 8941A97A3 for ; Mon, 6 Feb 2012 09:14:37 +0000 (UTC) Received: (qmail 66399 invoked by uid 500); 6 Feb 2012 09:14:36 -0000 Delivered-To: apmail-hc-commits-archive@hc.apache.org Received: (qmail 65486 invoked by uid 500); 6 Feb 2012 09:14:31 -0000 Mailing-List: contact commits-help@hc.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "HttpComponents Project" Delivered-To: mailing list commits@hc.apache.org Received: (qmail 65466 invoked by uid 99); 6 Feb 2012 09:14:28 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 06 Feb 2012 09:14:28 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 06 Feb 2012 09:14:25 +0000 Received: from eris.apache.org (localhost [127.0.0.1]) by eris.apache.org (Postfix) with ESMTP id B54122388ACC for ; Mon, 6 Feb 2012 09:14:03 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r1240940 [2/2] - in /httpcomponents/httpasyncclient/trunk: ./ httpasyncclient/src/main/java/org/apache/http/impl/nio/client/ httpasyncclient/src/main/java/org/apache/http/impl/nio/conn/ httpasyncclient/src/main/java/org/apache/http/nio/clie... Date: Mon, 06 Feb 2012 09:14:02 -0000 To: commits@hc.apache.org From: olegk@apache.org X-Mailer: svnmailer-1.0.8-patched Message-Id: <20120206091403.B54122388ACC@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Modified: httpcomponents/httpasyncclient/trunk/httpasyncclient/src/test/java/org/apache/http/nio/client/methods/TestZeroCopy.java URL: http://svn.apache.org/viewvc/httpcomponents/httpasyncclient/trunk/httpasyncclient/src/test/java/org/apache/http/nio/client/methods/TestZeroCopy.java?rev=1240940&r1=1240939&r2=1240940&view=diff ============================================================================== --- httpcomponents/httpasyncclient/trunk/httpasyncclient/src/test/java/org/apache/http/nio/client/methods/TestZeroCopy.java (original) +++ httpcomponents/httpasyncclient/trunk/httpasyncclient/src/test/java/org/apache/http/nio/client/methods/TestZeroCopy.java Mon Feb 6 09:14:01 2012 @@ -51,16 +51,17 @@ import org.apache.http.client.methods.Ht import org.apache.http.entity.BasicHttpEntity; import org.apache.http.entity.ContentType; import org.apache.http.impl.DefaultConnectionReuseStrategy; +import org.apache.http.impl.DefaultHttpResponseFactory; +import org.apache.http.impl.nio.DefaultNHttpServerConnection; import org.apache.http.impl.nio.DefaultNHttpServerConnectionFactory; import org.apache.http.nio.NHttpConnectionFactory; -import org.apache.http.nio.NHttpServerIOTarget; import org.apache.http.nio.entity.NFileEntity; import org.apache.http.nio.entity.NStringEntity; -import org.apache.http.nio.protocol.BufferingAsyncRequestHandler; +import org.apache.http.nio.protocol.BasicAsyncRequestHandler; import org.apache.http.nio.protocol.HttpAsyncExpectationVerifier; import org.apache.http.nio.protocol.HttpAsyncRequestHandlerRegistry; import org.apache.http.nio.protocol.HttpAsyncRequestHandlerResolver; -import org.apache.http.nio.protocol.HttpAsyncServiceHandler; +import org.apache.http.nio.protocol.HttpAsyncService; import org.apache.http.nio.reactor.IOReactorStatus; import org.apache.http.nio.reactor.ListenerEndpoint; import org.apache.http.params.HttpParams; @@ -88,7 +89,7 @@ public class TestZeroCopy extends HttpAs } @Override - protected NHttpConnectionFactory createServerConnectionFactory( + protected NHttpConnectionFactory createServerConnectionFactory( final HttpParams params) throws Exception { return new DefaultNHttpServerConnectionFactory(params); } @@ -101,11 +102,12 @@ public class TestZeroCopy extends HttpAs private HttpHost start( final HttpAsyncRequestHandlerResolver requestHandlerResolver, final HttpAsyncExpectationVerifier expectationVerifier) throws Exception { - HttpAsyncServiceHandler serviceHandler = new HttpAsyncServiceHandler( - requestHandlerResolver, - expectationVerifier, + HttpAsyncService serviceHandler = new HttpAsyncService( this.serverHttpProc, new DefaultConnectionReuseStrategy(), + new DefaultHttpResponseFactory(), + requestHandlerResolver, + expectationVerifier, this.serverParams); this.server.start(serviceHandler); this.httpclient.start(); @@ -193,7 +195,10 @@ public class TestZeroCopy extends HttpAs } @Override - protected Integer process(final HttpResponse response, final File file) throws Exception { + protected Integer process( + final HttpResponse response, + final File file, + final ContentType contentType) { return response.getStatusLine().getStatusCode(); } @@ -257,7 +262,7 @@ public class TestZeroCopy extends HttpAs @Test public void testTwoWayZeroCopy() throws Exception { HttpAsyncRequestHandlerRegistry registry = new HttpAsyncRequestHandlerRegistry(); - registry.register("*", new BufferingAsyncRequestHandler(new TestHandler(false))); + registry.register("*", new BasicAsyncRequestHandler(new TestHandler(false))); HttpHost target = start(registry, null); File tmpdir = FileUtils.getTempDirectory(); @@ -287,7 +292,7 @@ public class TestZeroCopy extends HttpAs @Test public void testZeroCopyFallback() throws Exception { HttpAsyncRequestHandlerRegistry registry = new HttpAsyncRequestHandlerRegistry(); - registry.register("*", new BufferingAsyncRequestHandler(new TestHandler(true))); + registry.register("*", new BasicAsyncRequestHandler(new TestHandler(true))); HttpHost target = start(registry, null); File tmpdir = FileUtils.getTempDirectory(); this.tmpfile = new File(tmpdir, "dst.test"); Modified: httpcomponents/httpasyncclient/trunk/pom.xml URL: http://svn.apache.org/viewvc/httpcomponents/httpasyncclient/trunk/pom.xml?rev=1240940&r1=1240939&r2=1240940&view=diff ============================================================================== --- httpcomponents/httpasyncclient/trunk/pom.xml (original) +++ httpcomponents/httpasyncclient/trunk/pom.xml Mon Feb 6 09:14:01 2012 @@ -71,7 +71,7 @@ 1.5 true true - 4.2-alpha2 + 4.2-beta1 4.1.2 1.1.1 2.0.1