jetty-9 - HTTP client: better logging for HttpExchange.

This commit is contained in:
Simone Bordet 2012-09-17 09:53:45 +02:00
parent 4ea5734ab1
commit 5aed22624f
1 changed files with 5 additions and 2 deletions

View File

@ -112,7 +112,7 @@ public class HttpExchange
if ((status & completed) == completed)
{
boolean success = status == 0b1111;
LOG.debug("{} complete success={}", this);
LOG.debug("{} complete success={}", this, success);
// Request and response completed
if (this == conversation.last())
conversation.complete();
@ -131,6 +131,9 @@ public class HttpExchange
@Override
public String toString()
{
return String.format("%s@%x", HttpExchange.class.getSimpleName(), hashCode());
return String.format("%s@%x status=%s",
HttpExchange.class.getSimpleName(),
hashCode(),
Integer.toBinaryString(complete.get()));
}
}