JUnit test fail to run when using the IBM JDK 1.6


(Paul Grove) #1

See details below this problem does not occur when using Sun JVM

Gradle build time: Thursday, 5 January 2012 10:24:43 o’clock UTC Groovy: 1.8.4 Ant: Apache Ant™ version 1.8.2 compiled on December 20 2010 Ivy: 2.2.0 JVM: 1.6.0 (IBM Corporation 2.4) OS: Windows XP 5.1 build 2600 Service Pack 3 x86

:compileJava UP-TO-DATE :processResources UP-TO-DATE :classes UP-TO-DATE :compileTestJava UP-TO-DATE :processTestResources UP-TO-DATE :testClasses UP-TO-DATE :test java.io.StreamCorruptedException: invalid stream header: BCDD0005

at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:794)

at java.io.ObjectInputStream.(ObjectInputStream.java:291)

at org.gradle.process.internal.launcher.GradleWorkerMain.run(GradleWorkerMain.java:28)

at org.gradle.process.internal.launcher.GradleWorkerMain.main(GradleWorkerMain.java:35) Could not write process standard input. java.io.IOException: The pipe has been ended.

at java.io.FileOutputStream.writeBytes(Native Method)

at java.io.FileOutputStream.write(FileOutputStream.java:266)

at java.io.BufferedOutputStream.flushBuffer(BufferedOutputStream.java:76)

at java.io.BufferedOutputStream.flush(BufferedOutputStream.java:134)

at org.gradle.process.internal.ExecOutputHandleRunner.run(ExecOutputHandleRunner.java:51)

at org.gradle.messaging.concurrent.DefaultExecutorFactory$StoppableExecutorImpl$1.run(DefaultExecutorFactory.jav a:64)

at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:896)

at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:918)

at java.lang.Thread.run(Thread.java:735) java.io.StreamCorruptedException: invalid stream header: BCDD0005

at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:794)

at java.io.ObjectInputStream.(ObjectInputStream.java:291)

at org.gradle.process.internal.launcher.GradleWorkerMain.run(GradleWorkerMain.java:28) Could not write process standard input. java.io.IOException: The pipe has been ended.

at java.io.FileOutputStream.writeBytes(Native Method)

at java.io.FileOutputStream.write(FileOutputStream.java:266)

at java.io.BufferedOutputStream.flushBuffer(BufferedOutputStream.java:76)

at java.io.BufferedOutputStream.flush(BufferedOutputStream.java:134)

at org.gradle.process.internal.ExecOutputHandleRunner.run(ExecOutputHandleRunner.java:51)

at org.gradle.messaging.concurrent.DefaultExecutorFactory$StoppableExecutorImpl$1.run(DefaultExecutorFactory.jav a:64)

at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:896)

at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:918)

at java.lang.Thread.run(Thread.java:735)

at org.gradle.process.internal.launcher.GradleWorkerMain.main(GradleWorkerMain.java:35) Gradle Worker 2 finished with (non-zero) exit value 1. org.gradle.process.internal.ExecException: Gradle Worker 2 finished with (non-zero) exit value 1.

at org.gradle.process.internal.DefaultExecHandle$ExecResultImpl.assertNormalExitValue(DefaultExecHandle.java:335 )

at org.gradle.process.internal.DefaultWorkerProcess.onProcessStop(DefaultWorkerProcess.java:78)

at org.gradle.process.internal.DefaultWorkerProcess.access$000(DefaultWorkerProcess.java:31)

at org.gradle.process.internal.DefaultWorkerProcess$1.executionFinished(DefaultWorkerProcess.java:51)

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:45)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37)

at java.lang.reflect.Method.invoke(Method.java:599)

at org.gradle.messaging.dispatch.ReflectionDispatch.dispatch(ReflectionDispatch.java:35)

at org.gradle.messaging.dispatch.ReflectionDispatch.dispatch(ReflectionDispatch.java:24)

at org.gradle.messaging.dispatch.BroadcastDispatch.dispatch(BroadcastDispatch.java:88)

at org.gradle.messaging.dispatch.BroadcastDispatch.dispatch(BroadcastDispatch.java:32)

at org.gradle.messaging.dispatch.AsyncDispatch.dispatchMessages(AsyncDispatch.java:132)

at org.gradle.messaging.dispatch.AsyncDispatch.access$000(AsyncDispatch.java:33)

at org.gradle.messaging.dispatch.AsyncDispatch$1.run(AsyncDispatch.java:72)

at org.gradle.messaging.concurrent.DefaultExecutorFactory$StoppableExecutorImpl$1.run(DefaultExecutorFactory.jav a:64)

at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:896)

at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:918)

at java.lang.Thread.run(Thread.java:735) java.io.StreamCorruptedException: invalid stream header: BCDD0005

at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:794)

at java.io.ObjectInputStream.(ObjectInputStream.java:291)

at org.gradle.process.internal.launcher.GradleWorkerMain.run(GradleWorkerMain.java:28)

at org.gradle.process.internal.launcher.GradleWorkerMain.main(GradleWorkerMain.java:35) Could not write process standard input. java.io.IOException: The pipe has been ended.

at java.io.FileOutputStream.writeBytes(Native Method)

at java.io.FileOutputStream.write(FileOutputStream.java:266)

at java.io.BufferedOutputStream.flushBuffer(BufferedOutputStream.java:76)

at java.io.BufferedOutputStream.flush(BufferedOutputStream.java:134)

at org.gradle.process.internal.ExecOutputHandleRunner.run(ExecOutputHandleRunner.java:51)

at org.gradle.messaging.concurrent.DefaultExecutorFactory$StoppableExecutorImpl$1.run(DefaultExecutorFactory.jav a:64)

at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:896)

at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:918)

at java.lang.Thread.run(Thread.java:735)


(Szczepan Faber) #2

Is it consistently failing? Would you be able to provide a sample project that demonstrates the issue?


(jtimreck76) #3

I am having the same issue, so I tried giving it a path to the IBM JVM manually using

test {

executable = ‘path’ }

It fails during VM creation when I execute the tasks with java but succeeds when executed with javaw.


(Szczepan Faber) #4

This problem is a manifestation of GRADLE-2290. We plan to fix it in Gradle 1.1.