提交 a1735c14 编写于 作者: K kohsuke

attempting to fix the performance problem in artifact archiving. Discovered on...

attempting to fix the performance problem in artifact archiving. Discovered on Sun's deployment, in the "glassfish-v3-main-publisher" job by Harsha.

git-svn-id: https://hudson.dev.java.net/svn/hudson/trunk/hudson/main@12475 71c3de6d-444a-0410-be80-ed276b4c234a
上级 a6c4a74c
......@@ -8,10 +8,11 @@ import org.codehaus.classworlds.NoSuchRealmException;
import java.io.File;
import java.io.FilterInputStream;
import java.io.FilterOutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.BufferedInputStream;
import java.io.BufferedOutputStream;
import java.lang.reflect.InvocationTargetException;
import java.net.Socket;
import java.util.HashSet;
......@@ -91,16 +92,16 @@ public class Main {
remotingLauncher.getMethod("main",new Class[]{InputStream.class,OutputStream.class}).invoke(null,
new Object[]{
// do partial close, since socket.getInputStream and getOutputStream doesn't do it by
new FilterInputStream(s.getInputStream()) {
new BufferedInputStream(new FilterInputStream(s.getInputStream()) {
public void close() throws IOException {
s.shutdownInput();
}
},
new RealFilterOutputStream(s.getOutputStream()) {
}),
new BufferedOutputStream(new RealFilterOutputStream(s.getOutputStream()) {
public void close() throws IOException {
s.shutdownOutput();
}
}
})
});
System.exit(0);
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册