Dear team, I have configured my Idea and Ubuntu environment to work with oracle java-jdk 14. Once I want to start the application I get a reflection error coming from Groovy. Here are the logs:
Java HotSpot(TM) 64-Bit Server VM warning: Options -Xverify:none and -noverify were deprecated in JDK 13 and will likely be removed in a future release.
java.lang.NoClassDefFoundError: Could not initialize class org.codehaus.groovy.vmplugin.v7.Java7
at org.codehaus.groovy.vmplugin.VMPluginFactory.<clinit>(VMPluginFactory.java:43)
at org.codehaus.groovy.reflection.GroovyClassValueFactory.<clinit>(GroovyClassValueFactory.java:35)
at org.codehaus.groovy.reflection.ClassInfo.<clinit>(ClassInfo.java:107)
at org.codehaus.groovy.reflection.ReflectionCache.getCachedClass(ReflectionCache.java:95)
at org.codehaus.groovy.reflection.ReflectionCache.<clinit>(ReflectionCache.java:39)
at org.codehaus.groovy.runtime.metaclass.MetaClassRegistryImpl.registerMethods(MetaClassRegistryImpl.java:209)
at org.codehaus.groovy.runtime.metaclass.MetaClassRegistryImpl.<init>(MetaClassRegistryImpl.java:107)
at org.codehaus.groovy.runtime.metaclass.MetaClassRegistryImpl.<init>(MetaClassRegistryImpl.java:85)
at groovy.lang.GroovySystem.<clinit>(GroovySystem.java:36)
at org.springframework.beans.factory.groovy.GroovyBeanDefinitionReader.<init>(GroovyBeanDefinitionReader.java:150)
at org.springframework.boot.BeanDefinitionLoader.<init>(BeanDefinitionLoader.java:85)
at org.springframework.boot.SpringApplication.createBeanDefinitionLoader(SpringApplication.java:738)
at org.springframework.boot.SpringApplication.load(SpringApplication.java:681)
After investigating a bit it boils down to spring-beans referencing a groovy version that is not supported on java 14. Is there any plan to upgrade dep, that fixes the issue?
Specs: * java version 14 * arch x64 * OS ubuntu 20.04 * spring-boot version 2.3.0-RELEASE
kr Nik
Comment From: wilkinsona
Spring Boot 2.3.0’s dependency management includes Groovy 2.5.11 what is compatible with Java 14. I would guess that you aren’t using Boot’s dependency management and have an earlier version of Groovy on the classpath.
If you believe you are using Boot’s dependency management and you would like us to spend some more time investigating, please spend some time providing a complete yet minimal sample that reproduces the problem. You can share it with us by pushing it to a separate repository on GitHub or by zipping it up and attaching it to this issue.
Comment From: spring-projects-issues
If you would like us to look at this issue, please provide the requested information. If the information is not provided within the next 7 days this issue will be closed.
Comment From: spring-projects-issues
Closing due to lack of requested feedback. If you would like us to look at this issue, please provide the requested information and we will re-open the issue.