New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support for shared GroovyClassLoader in GroovyScriptFactory #25177
Comments
How are you defining those 3000 Groovy scripts? Are you using the XML scripting support or manual FWIW, this is by far the largest-scale use of Spring's scripting support that I ever heard of... |
Since the common solution for Note that this won't be working quite yet: We would still have to patch |
A quick update: The context-level We intend to initially ship this patch in our upcoming 5.2.7 and 5.1.16 releases next week, then subsequently in 5.0.18 and 4.3.28 at a later point. |
Please note that due to the adaptive |
Exposes setClassLoader method in ConfigurableApplicationContext interface as obvious first-class configuration option. Closes spring-projectsgh-25177
Affects: Spring Framework 4.3.4
I use
ScriptFactoryPostProcessor
to create Groovy class bean and register in spring context. I have three thousand groovy file need to load.I debug spring code and found that Spring uses
GroovyScriptFactory
to parse groovy class, but every time a newGroovyClassLoader
is used and caues JVM metaspace space error.Issue
why Every time new
GroovyScriptFactory
instance to parse groovy?groovy in jave8 has metaspace bug. see
https://stackoverflow.com/questions/37301117/java-groovy-memory-leak-in-groovyclassloader
To solve this bug, we need to use global
GroovyClassLoader
instance to parse groovy.how to solve ?
The text was updated successfully, but these errors were encountered: