Improved logging.

This commit is contained in:
Simone Bordet 2016-05-20 01:12:12 +02:00
parent faec7259b2
commit d55aaa4a0c
2 changed files with 9 additions and 2 deletions

View File

@ -150,7 +150,7 @@ public class BufferingFlowControlStrategy extends AbstractFlowControlStrategy
else else
{ {
if (LOG.isDebugEnabled()) if (LOG.isDebugEnabled())
LOG.debug("Data consumed, stream recv window level {}/{} for {}", level, maxLevel, session); LOG.debug("Data consumed, stream recv window level {}/{} for {}", level, maxLevel, stream);
} }
} }
} }
@ -202,10 +202,11 @@ public class BufferingFlowControlStrategy extends AbstractFlowControlStrategy
@Override @Override
public String toString() public String toString()
{ {
return String.format("%s@%x[ratio=%.2f,sessionStallTime=%dms,streamsStallTime=%dms]", return String.format("%s@%x[ratio=%.2f,sessionLevel=%s,sessionStallTime=%dms,streamsStallTime=%dms]",
getClass().getSimpleName(), getClass().getSimpleName(),
hashCode(), hashCode(),
bufferRatio, bufferRatio,
sessionLevel,
getSessionStallTime(), getSessionStallTime(),
getStreamsStallTime()); getStreamsStallTime());
} }

View File

@ -276,4 +276,10 @@ public class HttpChannelOverHTTP2 extends HttpChannel
} }
} }
} }
@Override
public String toString()
{
return String.format("%s#%d", super.toString(), getStream().getId());
}
} }