Building Loom from Maven

Rob Bygrave robin.bygrave at gmail.com
Mon Aug 8 21:30:37 UTC 2022


maven-compiler-plugin version *3.8.1* is kind of old.   Maybe try
version *3.10.1
*?

On Fri, 5 Aug 2022 at 04:02, Lutz Horn <code at lhorn.de> wrote:

> Hi,
>
> Am 04.08.22 um 02:33 schrieb eric at kolotyluk.net:
> > Has anyone had any success using Structured Concurrency from JDK 19?
>
> Using 19.ea.33-open from SDKMAN, this makes `mvn compile` work:
>
> ```
> <plugin>
>    <groupId>org.apache.maven.plugins</groupId>
>    <artifactId>maven-compiler-plugin</artifactId>
>    <version>3.8.1</version>
>    <configuration>
>      <release>19</release>
>      <compilerArgs>
>        <arg>--enable-preview</arg>
>        <arg>--add-modules</arg>
>        <arg>jdk.incubator.concurrent</arg>
>      </compilerArgs>
>    </configuration>
> </plugin>
> ```
>
> Note that `--add-modules jdk.incubator.concurrent` ist split on *two*
> `arg`s.
>
>
> Strangely, I fail to run `mvn test` using the following configuration of
> the `maven-surefire-plugin` which worked with the old Loom preview build
> 19.ea.5.lm-open.
>
> ```
> <configuration>
>    <argLine>--enable-preview --add-modules
> jdk.incubator.concurrent</argLine>
> </configuration>
> ```
>
> `mvn test-compile` works but `mvn test` fails like this:
>
> ```
> java.lang.NoSuchMethodError: 'void
> jdk.incubator.concurrent.StructuredTaskScope$ShutdownOnFailure.join()'
> ```
>
> Both `main` and `test` can be compiled but running the tests fails.
>
> Lutz
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.openjdk.org/pipermail/loom-dev/attachments/20220809/6435af59/attachment-0001.htm>


More information about the loom-dev mailing list