log tweak

This commit is contained in:
zzz
2012-03-01 23:52:56 +00:00
parent 33964fac45
commit 75eda7e1b1

View File

@@ -161,8 +161,7 @@ class ConnectionManager {
// active++; // active++;
//} //}
if (locked_tooManyStreams()) { if (locked_tooManyStreams()) {
if (_log.shouldLog(Log.WARN)) _log.logAlways(Log.WARN, "Refusing connection since we have exceeded our max of "
_log.warn("Refusing connection since we have exceeded our max of "
+ _maxConcurrentStreams + " connections"); + _maxConcurrentStreams + " connections");
reject = true; reject = true;
} else { } else {
@@ -233,8 +232,7 @@ class ConnectionManager {
while (true) { while (true) {
long remaining = expiration - _context.clock().now(); long remaining = expiration - _context.clock().now();
if (remaining <= 0) { if (remaining <= 0) {
if (_log.shouldLog(Log.WARN)) _log.logAlways(Log.WARN, "Refusing to connect since we have exceeded our max of "
_log.warn("Refusing to connect since we have exceeded our max of "
+ _maxConcurrentStreams + " connections"); + _maxConcurrentStreams + " connections");
_numWaiting--; _numWaiting--;
return null; return null;
@@ -243,8 +241,7 @@ class ConnectionManager {
if (locked_tooManyStreams()) { if (locked_tooManyStreams()) {
// allow a full buffer of pending/waiting streams // allow a full buffer of pending/waiting streams
if (_numWaiting > _maxConcurrentStreams) { if (_numWaiting > _maxConcurrentStreams) {
if (_log.shouldLog(Log.WARN)) _log.logAlways(Log.WARN, "Refusing connection since we have exceeded our max of "
_log.warn("Refusing connection since we have exceeded our max of "
+ _maxConcurrentStreams + " and there are " + _numWaiting + _maxConcurrentStreams + " and there are " + _numWaiting
+ " waiting already"); + " waiting already");
_numWaiting--; _numWaiting--;