You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hc.apache.org by ol...@apache.org on 2016/10/03 19:28:21 UTC
svn commit: r1763199 [2/2] - in /httpcomponents/httpcore/trunk:
httpcore5-h2/src/main/java/org/apache/hc/core5/http2/bootstrap/
httpcore5-h2/src/main/java/org/apache/hc/core5/http2/bootstrap/nio/
httpcore5-h2/src/main/java/org/apache/hc/core5/http2/imp...
Modified: httpcomponents/httpcore/trunk/httpcore5/src/test/java/org/apache/hc/core5/http/impl/nio/TestHttpMessageParser.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpcore/trunk/httpcore5/src/test/java/org/apache/hc/core5/http/impl/nio/TestHttpMessageParser.java?rev=1763199&r1=1763198&r2=1763199&view=diff
==============================================================================
--- httpcomponents/httpcore/trunk/httpcore5/src/test/java/org/apache/hc/core5/http/impl/nio/TestHttpMessageParser.java (original)
+++ httpcomponents/httpcore/trunk/httpcore5/src/test/java/org/apache/hc/core5/http/impl/nio/TestHttpMessageParser.java Mon Oct 3 19:28:20 2016
@@ -35,9 +35,9 @@ import java.nio.channels.ReadableByteCha
import java.nio.charset.Charset;
import java.nio.charset.StandardCharsets;
-import org.apache.hc.core5.http.HttpException;
import org.apache.hc.core5.http.ClassicHttpRequest;
import org.apache.hc.core5.http.ClassicHttpResponse;
+import org.apache.hc.core5.http.HttpException;
import org.apache.hc.core5.http.MessageConstraintException;
import org.apache.hc.core5.http.UnsupportedHttpVersionException;
import org.apache.hc.core5.http.config.MessageConstraints;
Modified: httpcomponents/httpcore/trunk/httpcore5/src/test/java/org/apache/hc/core5/http/testserver/io/HttpServer.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpcore/trunk/httpcore5/src/test/java/org/apache/hc/core5/http/testserver/io/HttpServer.java?rev=1763199&r1=1763198&r2=1763199&view=diff
==============================================================================
--- httpcomponents/httpcore/trunk/httpcore5/src/test/java/org/apache/hc/core5/http/testserver/io/HttpServer.java (original)
+++ httpcomponents/httpcore/trunk/httpcore5/src/test/java/org/apache/hc/core5/http/testserver/io/HttpServer.java Mon Oct 3 19:28:20 2016
@@ -36,7 +36,7 @@ import java.util.concurrent.TimeUnit;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.apache.hc.core5.http.ConnectionClosedException;
-import org.apache.hc.core5.http.ExceptionLogger;
+import org.apache.hc.core5.http.ExceptionListener;
import org.apache.hc.core5.http.bootstrap.io.ServerBootstrap;
import org.apache.hc.core5.http.config.SocketConfig;
import org.apache.hc.core5.http.io.HttpConnectionFactory;
@@ -102,7 +102,7 @@ public class HttpServer {
.build())
.setServerInfo("TEST-SERVER/1.1")
.setConnectionFactory(new LoggingConnFactory())
- .setExceptionLogger(new SimpleExceptionLogger())
+ .setExceptionListener(new SimpleExceptionListener())
.setExpectationVerifier(this.expectationVerifier)
.setHandlerMapper(this.reqistry)
.create();
@@ -127,12 +127,12 @@ public class HttpServer {
}
}
- static class SimpleExceptionLogger implements ExceptionLogger {
+ static class SimpleExceptionListener implements ExceptionListener {
private final Log log = LogFactory.getLog(HttpServer.class);
@Override
- public void log(final Exception ex) {
+ public void onError(final Exception ex) {
if (ex instanceof ConnectionClosedException) {
this.log.debug(ex.getMessage());
} else if (ex instanceof SocketException) {
Modified: httpcomponents/httpcore/trunk/httpcore5/src/test/java/org/apache/hc/core5/http/testserver/nio/HttpServerNio.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpcore/trunk/httpcore5/src/test/java/org/apache/hc/core5/http/testserver/nio/HttpServerNio.java?rev=1763199&r1=1763198&r2=1763199&view=diff
==============================================================================
--- httpcomponents/httpcore/trunk/httpcore5/src/test/java/org/apache/hc/core5/http/testserver/nio/HttpServerNio.java (original)
+++ httpcomponents/httpcore/trunk/httpcore5/src/test/java/org/apache/hc/core5/http/testserver/nio/HttpServerNio.java Mon Oct 3 19:28:20 2016
@@ -34,7 +34,7 @@ import java.util.concurrent.TimeUnit;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.apache.hc.core5.http.ConnectionClosedException;
-import org.apache.hc.core5.http.ExceptionLogger;
+import org.apache.hc.core5.http.ExceptionListener;
import org.apache.hc.core5.http.bootstrap.nio.HttpServer;
import org.apache.hc.core5.http.bootstrap.nio.ServerBootstrap;
import org.apache.hc.core5.http.impl.nio.DefaultNHttpServerConnection;
@@ -62,7 +62,7 @@ public class HttpServerNio {
.setIOReactorConfig(reactorConfig)
.setServerInfo("TEST-SERVER/1.1")
.setConnectionFactory(connectionFactory)
- .setExceptionLogger(new SimpleExceptionLogger())
+ .setExceptionListener(new SimpleExceptionListener())
.setExpectationVerifier(expectationVerifier)
.setHttpProcessor(httpProcessor)
.setHandlerMapper(this.reqistry)
@@ -91,12 +91,12 @@ public class HttpServerNio {
this.server.shutdown(5, TimeUnit.SECONDS);
}
- static class SimpleExceptionLogger implements ExceptionLogger {
+ static class SimpleExceptionListener implements ExceptionListener {
private final Log log = LogFactory.getLog(HttpServer.class);
@Override
- public void log(final Exception ex) {
+ public void onError(final Exception ex) {
if (ex instanceof ConnectionClosedException) {
this.log.debug(ex.getMessage());
} else if (ex instanceof SocketException) {