[YANGTOOLS-313] Duplicate ConcreteTypeImpl classes Created: 16/Sep/14  Updated: 10/Apr/22  Resolved: 16/Oct/14

Status: Resolved
Project: yangtools
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Improvement
Reporter: Robert Varga Assignee: Robert Varga
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

Operating System: All
Platform: All



 Description   

Analysis of a freshly-booted SP edition indicates that there are ~6400 duplicates of String("QName") and ~5600 duplicates of String("Serializable"), wasting 720KiB of memory.

Deeper analysis shows that these come from duplicate objects returned from org.opendaylight.yangtools.binding.generator.util.Types.typeForClass().

Address this by instantiating a weakly-keyed, soft-valued cache of these objects.



 Comments   
Comment by Robert Varga [ 16/Sep/14 ]

https://git.opendaylight.org/gerrit/#/c/11225/

Generated at Wed Feb 07 20:52:51 UTC 2024 using Jira 8.20.10#820010-sha1:ace47f9899e9ee25d7157d59aa17ab06aee30d3d.