提交 570e2719 编写于 作者: K kohsuke

to assist further trouble-shooting, have the thread name refer to bits that...

to assist further trouble-shooting, have the thread name refer to bits that it's trying to write while blocking.

git-svn-id: https://hudson.dev.java.net/svn/hudson/trunk/hudson/main@34829 71c3de6d-444a-0410-be80-ed276b4c234a
上级 264666fc
......@@ -149,10 +149,15 @@ public class FastPipedOutputStream extends OutputStream {
byte[] buf = s.buffer;
s = null;
Thread t = Thread.currentThread();
String oldName = t.getName();
t.setName("Blocking to write '"+HexDump.toHex(b,off,Math.min(len,256))+"' : "+oldName);
try {
buf.wait(TIMEOUT);
} catch (InterruptedException e) {
throw (InterruptedIOException)new InterruptedIOException(e.getMessage()).initCause(e);
} finally {
t.setName(oldName);
}
// Try again.
continue;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册