Hi all,

We are close to getting Micronaut's JDK 16 builds passing however some
tests are failing that are related to Groovy and Spock that I am unsure how
to fix.

Most of the errors are like:

java.lang.reflect.InvocationTargetException
    at org.codehaus.groovy.vmplugin.v9.Java9.of(Java9.java:160)
    at
org.codehaus.groovy.vmplugin.v9.Java9.getInvokeSpecialHandle(Java9.java:179)
    at
java.base/java.util.concurrent.ConcurrentHashMap.computeIfAbsent(ConcurrentHashMap.java:1708)
    at io.micronaut.core.io.WritableSpec.test flush is
called(WritableSpec.groovy:13)
Caused by: java.lang.IllegalAccessException: module jdk.proxy3 does not
open jdk.proxy3 to unnamed module @71559e7c
    at
java.base/java.lang.invoke.MethodHandles.privateLookupIn(MethodHandles.java:260)
    ... 4 more

Which seems to be related to the creation of proxies for closures as the
code in question that fails looks like:

    @Get(value = "/welcome", produces = MediaType.TEXT_PLAIN)
    Writable render() { // <2>
        { writer ->
            template.make( // <3>
                    firstName: "Fred",
                    lastName: "Flintstone"
            ).writeTo(writer)
        }
    }

There is a single other failure with this Spock error message:

Caused by: java.lang.reflect.InaccessibleObjectException: Unable to make
field static final java.lang.invoke.MethodHandles$Lookup
java.lang.invoke.MethodHandles$Lookup.IMPL_LOOKUP accessible: module
java.base does not "opens java.lang.invoke" to unnamed module @533e0c7
    at
org.spockframework.mock.runtime.DefaultMethodInvoker.respond(DefaultMethodInvoker.java:50)
    ... 27 more


Are these problems something that has been resolved or being looked at? I
haven't seen anything with a brief look through the issue tracker.

Thanks for the feedback
-- 
Graeme Rocher

Reply via email to