Skip to content

PermGen leak in GenericTypeResolver's typeVariableCache [SPR-5462] #10135

@spring-projects-issues

Description

@spring-projects-issues

Wesley Hartford opened SPR-5462 and commented

I have a class SimpleXPathQueryCriteriaQueryGenerator extends AbstractSimpleCriteriaQueryGenerator<XPathQuery> implements XPathQueryCriteriaQueryGenerator. All four of these classes are loaded by the same URLClassLoader, which should be discarded at some point, all of spring is loaded by the parent ClassLoader, which stays around for a long time.

As far as I can tell, the org.springframework.core.GenericTypeResolver keeps a static WeakHashMap containing the SimpleXPathQueryCriteriaQueryGenerator as the key, and the XPathQuery contained in a map withing the value. The XPathQuery in the value results in a hard reference path back to the key of the WeakHashMap.


Affects: 2.5.5

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions