Memory increasing when a large number of beans managed by swiz due to typeDescriptor cache.

Description

If we profile an application with a large number of beans managed by swiz we notice a large amount of memory occupied by the property description of type XML which is stored inside the typeDescriptor.

Swiz should store all data it requires to work (similar to what it's already doing with constants) and dispose the XML. From a brief scan, one ClassConstants and EventHandlerProcessor requires information from the descriptor, so that data should be stored within the TypeDescriptor.

Since ClassConstants and EventHandlerProcessor will lookup by name, eventually while parsing the describeType info, it should store it in a Object/dictionary so it would be faster finding, eventually adding an API hasContant(),HasProperty(),getConstant(),getProperty().

Environment

Any

Status

Assignee

ChrisC

Reporter

João Fernandes

Labels

None

Affects versions

Priority

Major
Configure