cpovirk opened a new issue, #3511: URL: https://github.com/apache/maven-surefire/issues/3511
### Affected version 3.6.0 ### Bug description We're seeing this in https://github.com/google/guava: ```shell $ git checkout 99dfa90a138b9d833a9b144dab22991dbaab0288 $ perl -pi -e 's/\d[\d.]+/3.6.0/ if /maven-surefire-plugin.version/' pom.xml $ JAVA_HOME=/usr/local/google/home/cpovirk/jdk-26+35 ./mvnw clean install -Dsurefire.toolchain.version=11 ... [ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:3.6.0:test (default-test) on project guava-tests: [ERROR] [ERROR] See /usr/local/google/home/cpovirk/clients/guava-black/guava/guava-tests/target/surefire-reports for the individual test results. [ERROR] See dump files (if any exist) [date].dump, [date]-jvmRun[N].dump and [date].dumpstream. [ERROR] There was an error in the forked process [ERROR] java.lang.IllegalAccessError: failed to access class com.google.common.collect.testing.AbstractIteratorTester from class com.google.common.collect.MinMaxPriorityQueueTest (com.google.common.collect.testing.AbstractIteratorTester and com.google.common.collect.MinMaxPriorityQueueTest are in unnamed module of loader 'app') [ERROR] org.apache.maven.surefire.booter.SurefireBooterForkException: There was an error in the forked process [ERROR] java.lang.IllegalAccessError: failed to access class com.google.common.collect.testing.AbstractIteratorTester from class com.google.common.collect.MinMaxPriorityQueueTest (com.google.common.collect.testing.AbstractIteratorTester and com.google.common.collect.MinMaxPriorityQueueTest are in unnamed module of loader 'app') [ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:708) [ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:523) [ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:323) [ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:287) [ERROR] at org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeProvider(AbstractSurefireMojo.java:1474) [ERROR] at org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeAfterPreconditionsChecked(AbstractSurefireMojo.java:1246) [ERROR] at org.apache.maven.plugin.surefire.AbstractSurefireMojo.execute(AbstractSurefireMojo.java:1082) [ERROR] at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:126) [ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute2(MojoExecutor.java:328) [ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute(MojoExecutor.java:316) [ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:212) [ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:174) [ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.access$000(MojoExecutor.java:75) [ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor$1.run(MojoExecutor.java:162) [ERROR] at org.apache.maven.plugin.DefaultMojosExecutionStrategy.execute(DefaultMojosExecutionStrategy.java:39) [ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:159) [ERROR] at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:105) [ERROR] at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:73) [ERROR] at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:53) [ERROR] at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:118) [ERROR] at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:261) [ERROR] at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:173) [ERROR] at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:101) [ERROR] at org.apache.maven.cli.MavenCli.execute(MavenCli.java:919) [ERROR] at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:285) [ERROR] at org.apache.maven.cli.MavenCli.main(MavenCli.java:207) [ERROR] at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:104) [ERROR] at java.base/java.lang.reflect.Method.invoke(Method.java:565) [ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:255) [ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:201) [ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:361) [ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:314) [ERROR] at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:104) [ERROR] at java.base/java.lang.reflect.Method.invoke(Method.java:565) [ERROR] at org.apache.maven.wrapper.BootstrapMainStarter.start(BootstrapMainStarter.java:52) [ERROR] at org.apache.maven.wrapper.WrapperExecutor.execute(WrapperExecutor.java:161) [ERROR] at org.apache.maven.wrapper.MavenWrapperMain.main(MavenWrapperMain.java:73) ``` Additionally, when I omit `-Dsurefire.toolchain.version` (which causes our build to use Java 26 for Surefire), I am seeing very slow execution for the tests of our `guava-tests` module: That historically has taken ~5 minutes of a total build time of ~7 minutes, but I stopped the build that was using 3.6.0 after about 40 minutes, when it appeared to have been running the same test classes (e.g., `com.google.common.collect.testing.testers.CollectionClearTester`) repeatedly. That may be a separate issue, probably related to how our tests [build custom JUnit 3 suites](https://github.com/google/guava/blob/99dfa90a138b9d833a9b144dab22991dbaab0288/guava-tests/test/com/google/common/collect/ImmutableListTest.java#L76). But from the release notes, I wonder if both symptoms might be a result of https://github.com/apache/maven-surefire/pull/3444. I tried to build my own Surefire at that commit, but (if I did things correct and I'm remembering correctly) I saw _no_ tests run at that commit. W hen I tried to bisect the no-tests issue from there, I ran into trouble with our internal Maven mirror, and I gave up. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
