[tomcat] branch master updated: Add some debug to show buffering differences

2019-11-12 Thread remm
This is an automated email from the ASF dual-hosted git repository.

remm pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/master by this push:
 new d09f468  Add some debug to show buffering differences
d09f468 is described below

commit d09f46896da11baba121628a67d3afe8a4bc0c8f
Author: remm 
AuthorDate: Tue Nov 12 16:13:43 2019 +0100

Add some debug to show buffering differences
---
 test/org/apache/catalina/nonblocking/TestNonBlockingAPI.java | 4 
 1 file changed, 4 insertions(+)

diff --git a/test/org/apache/catalina/nonblocking/TestNonBlockingAPI.java 
b/test/org/apache/catalina/nonblocking/TestNonBlockingAPI.java
index 042b6f3..7f16f26 100644
--- a/test/org/apache/catalina/nonblocking/TestNonBlockingAPI.java
+++ b/test/org/apache/catalina/nonblocking/TestNonBlockingAPI.java
@@ -192,11 +192,15 @@ public class TestNonBlockingAPI extends TomcatBaseTest {
 int readSinceLastPause = 0;
 while (read != -1) {
 read = is.read(buffer);
+if (readSinceLastPause == 0) {
+log.info("Reading data");
+}
 if (read > 0) {
 result.append(buffer, 0, read);
 }
 readSinceLastPause += read;
 if (readSinceLastPause > WRITE_SIZE / 16) {
+log.info("Read " + readSinceLastPause + " bytes, pause 500ms");
 readSinceLastPause = 0;
 Thread.sleep(500);
 }


-
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org



[tomcat] branch master updated: Add some debug

2019-04-15 Thread remm
This is an automated email from the ASF dual-hosted git repository.

remm pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/master by this push:
 new 06f456f  Add some debug
06f456f is described below

commit 06f456f762dc1b6fa5df44da9f0c3cf70ae202f0
Author: remm 
AuthorDate: Mon Apr 15 15:32:55 2019 +0200

Add some debug
---
 java/org/apache/coyote/http2/Http2AsyncParser.java   | 3 +++
 java/org/apache/coyote/http2/LocalStrings.properties | 1 +
 2 files changed, 4 insertions(+)

diff --git a/java/org/apache/coyote/http2/Http2AsyncParser.java 
b/java/org/apache/coyote/http2/Http2AsyncParser.java
index 92531bf..d8f2767 100644
--- a/java/org/apache/coyote/http2/Http2AsyncParser.java
+++ b/java/org/apache/coyote/http2/Http2AsyncParser.java
@@ -237,6 +237,9 @@ class Http2AsyncParser extends Http2Parser {
 // Always a fatal IO error
 error = e;
 if (state == null || state == CompletionState.DONE) {
+if (log.isDebugEnabled()) {
+log.debug(sm.getString("http2Parser.error", connectionId, 
Integer.valueOf(streamId), frameType), e);
+}
 upgradeHandler.upgradeDispatch(SocketEvent.ERROR);
 }
 }
diff --git a/java/org/apache/coyote/http2/LocalStrings.properties 
b/java/org/apache/coyote/http2/LocalStrings.properties
index 1320e60..17dbf88 100644
--- a/java/org/apache/coyote/http2/LocalStrings.properties
+++ b/java/org/apache/coyote/http2/LocalStrings.properties
@@ -44,6 +44,7 @@ hpackdecoder.zeroNotValidHeaderTableIndex=Zero is not a valid 
header table index
 hpackhuffman.huffmanEncodedHpackValueDidNotEndWithEOS=Huffman encoded value in 
HPACK headers did not end with EOS padding
 hpackhuffman.stringLiteralTooMuchPadding=More than 7 bits of EOS padding were 
provided at the end of an Huffman encoded string literal
 
+http2Parser.error=Connection [{0}], Stream [{1}], Frame type [{2}], Error
 http2Parser.headerLimitCount=Connection [{0}], Stream [{1}], Too many headers
 http2Parser.headerLimitSize=Connection [{0}], Stream [{1}], Total header size 
too big
 http2Parser.headers.wrongFrameType=Connection [{0}], headers in progress for 
stream [{1}] but a frame of type [{2}] was received


-
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org