Byteman and JDK 10.0.1
ehugonnet Jun 20, 2018 6:20 AMHi,
While my test using BMUnit is working nicely on Java 9 it fails on Oracle JDK 10.0.1 with the following error from Surefire :
# Created at 2018-06-20T12:08:53.880
Corrupted STDOUT by directly writing to native stream in forked JVM 1. Stream 'Invoking lock of ContentRepositoryImpl'.
java.lang.IllegalArgumentException: Stream stdin corrupted. Expected comma after third character in command 'Invoking lock of ContentRepositoryImpl'.
at org.apache.maven.plugin.surefire.booterclient.output.ForkClient$OperationalData.<init>(ForkClient.java:511)
at org.apache.maven.plugin.surefire.booterclient.output.ForkClient.processLine(ForkClient.java:209)
at org.apache.maven.plugin.surefire.booterclient.output.ForkClient.consumeLine(ForkClient.java:176)
at org.apache.maven.plugin.surefire.booterclient.output.ThreadedStreamConsumer$Pumper.run(ThreadedStreamConsumer.java:88)
at java.base/java.lang.Thread.run(Thread.java:844)
.... which are traceln in my rule.
And I have the following message in maven console :
[WARNING] Corrupted STDOUT by directly writing to native stream in forked JVM 1. See FAQ web page and the dump file /home/ehsavoie/dev/wildfly/core/deployment-repository/target/surefire-reports/2018-06-20T12-10-52_497-jvmRun1.dumpstream
[DEBUG] Creating countDown for org.jboss.as.repository.ContentRepositoryImpl@32b260fa
[DEBUG] Invoking lock of ContentRepositoryImpl
[DEBUG] org.jboss.as.repository.ContentRepositoryImpl.lock(ContentRepositoryImpl.java:526)
[DEBUG] org.jboss.as.repository.ContentRepositoryImpl.removeContent(ContentRepositoryImpl.java:297)
[DEBUG] org.jboss.as.repository.DeletionCollisionTest.lambda$testFileLockByRemoveContent$2(DeletionCollisionTest.java:108)
[DEBUG] java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:514)
[DEBUG] java.util.concurrent.FutureTask.run(FutureTask.java:264)
[DEBUG] java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1135)
[DEBUG] java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
[DEBUG] java.lang.Thread.run(Thread.java:844)
[DEBUG] I'm byteman and waiting for 3s org.jboss.as.repository.ContentRepositoryImpl@32b260fa
which leads me to think that the rule is working properly.
....
The forked VM terminated without properly saying goodbye. VM crash or System.exit called?
Command was /bin/sh -c cd /home/ehsavoie/dev/wildfly/core/deployment-repository && /usr/lib/jvm/java-10-oracle/bin/java -javaagent:/home/ehsavoie/.m2/repository/org/jboss/byteman/byteman/4.0.2/byteman-4.0.2.jar=port:17091,address:127.0.0.1,boot:/home/ehsavoie/.m2/repository/org/jboss/byteman/byteman/4.0.2/byteman-4.0.2.jar --add-exports=java.base/sun.nio.ch=ALL-UNNAMED --illegal-access=permit -Dsun.util.logging.disableCallerCheck=true -Djdk.attach.allowAttachSelf=true -ea -Duser.region=US -Duser.language=en -Duser.timezone=America/Chicago -XX:MaxMetaspaceSize=256m -jar /home/ehsavoie/dev/wildfly/core/deployment-repository/target/surefire/surefirebooter1741649362879056134.jar /home/ehsavoie/dev/wildfly/core/deployment-repository/target/surefire 2018-06-20T12-10-52_497-jvmRun1 surefire3786702292358327602tmp surefire_01211028534385003857tmp
Process Exit Code: 0
Crashed tests:
org.jboss.as.repository.DeletionCollisionTest
I've tried to update to the latest versions of Surefire / Byteman (aka 4.0.2 and even current master) with no changes at all in the 'result'.
Am I missing something ?