This is an automated email from the ASF dual-hosted git repository.
markt 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 800bd8a Improve logging when streams cannot be pruned.
800bd8a is described below
commit 800bd8a6a5d22127e37861f56f1217b2eee4514b
Author: Mark Thomas <[email protected]>
AuthorDate: Wed Mar 6 18:13:12 2019 +0000
Improve logging when streams cannot be pruned.
This is to provide additional information to investigate reports like
https://bz.apache.org/bugzilla/show_bug.cgi?id=63223
---
java/org/apache/coyote/http2/Http2UpgradeHandler.java | 6 +++---
java/org/apache/coyote/http2/LocalStrings.properties | 2 +-
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/java/org/apache/coyote/http2/Http2UpgradeHandler.java
b/java/org/apache/coyote/http2/Http2UpgradeHandler.java
index 74b0023..4189a3f 100644
--- a/java/org/apache/coyote/http2/Http2UpgradeHandler.java
+++ b/java/org/apache/coyote/http2/Http2UpgradeHandler.java
@@ -1000,7 +1000,7 @@ class Http2UpgradeHandler extends AbstractStream
implements InternalHttpUpgradeH
sm.getString("upgradeHandler.stream.even", key),
Http2Error.PROTOCOL_ERROR);
}
- pruneClosedStreams();
+ pruneClosedStreams(streamId);
Stream result = new Stream(key, this);
streams.put(key, result);
@@ -1034,7 +1034,7 @@ class Http2UpgradeHandler extends AbstractStream
implements InternalHttpUpgradeH
}
- private void pruneClosedStreams() {
+ private void pruneClosedStreams(int streamId) {
// Only prune every 10 new streams
if (newStreamsSinceLastPrune < 9) {
// Not atomic. Increments may be lost. Not a problem.
@@ -1146,7 +1146,7 @@ class Http2UpgradeHandler extends AbstractStream
implements InternalHttpUpgradeH
if (toClose > 0) {
log.warn(sm.getString("upgradeHandler.pruneIncomplete",
connectionId,
- Integer.toString(toClose)));
+ Integer.toString(streamId), Integer.toString(toClose)));
}
}
diff --git a/java/org/apache/coyote/http2/LocalStrings.properties
b/java/org/apache/coyote/http2/LocalStrings.properties
index 3fc7000..c948c29 100644
--- a/java/org/apache/coyote/http2/LocalStrings.properties
+++ b/java/org/apache/coyote/http2/LocalStrings.properties
@@ -128,7 +128,7 @@ upgradeHandler.notifyAll=Connection [{0}], Stream [{1}],
notifyAll() called to r
upgradeHandler.pause.entry=Connection [{0}] Pausing
upgradeHandler.pingFailed=Connection [{0}] Failed to send ping to client
upgradeHandler.prefaceReceived=Connection [{0}], Connection preface received
from client
-upgradeHandler.pruneIncomplete=Connection [{0}] Failed to fully prune the
connection because streams were active / used in the priority tree. There are
[{1}] too many streams
+upgradeHandler.pruneIncomplete=Connection [{0}], Stream [{1}], Failed to fully
prune the connection because there are [{2}] too many active streams
upgradeHandler.pruneStart=Connection [{0}] Starting pruning of old streams.
Limit is [{1}] + 10% and there are currently [{2}] streams.
upgradeHandler.pruned=Connection [{0}] Pruned completed stream [{1}]
upgradeHandler.prunedPriority=Connection [{0}] Pruned unused stream [{1}] that
may have been part of the priority tree
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]