[
https://issues.apache.org/jira/browse/GROOVY-11240?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Daniel Sun resolved GROOVY-11240.
---------------------------------
Resolution: Fixed
> Tweak cleanup DFA cache of parser
> ---------------------------------
>
> Key: GROOVY-11240
> URL: https://issues.apache.org/jira/browse/GROOVY-11240
> Project: Groovy
> Issue Type: Improvement
> Reporter: Daniel Sun
> Assignee: Daniel Sun
> Priority: Major
> Fix For: 5.0.0-alpha-4
>
>
> We should keep the DFA cache as long as possible for better parsing
> performance, but the DFA cache may be very huge and results in OOM usually if
> we do not handle it correctly.
> Our current solution is to set a threshold to cleanup DFA cache, but the
> threshold is hard for users to evaluate for a reasonable value.
> The new solution relies on GC, if the object referenced by soft reference is
> collected by GC, we trigger the cleanup of DFA cache. We just need set the
> threshold to {{0}} to enable the smart cleanup.
> For better compatibility, we keep the existing cleanup setting as it is.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)