[YANGTOOLS-495] Allow SchemaContext shed YANG sources Created: 05/Sep/15  Updated: 10/Apr/22  Resolved: 10/Nov/15

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

Type: Improvement
Reporter: Robert Varga Assignee: Unassigned
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   

NETCONF/L2FIB test shows that a SchemaContext instance can take up as much as 1.8MB of memory, with a lot of that overhead coming from ModuleImpl retaining a reference to the YANG file source.

Analyze usage scenarios and we can make the source lazily-loaded, such that we do not keep it in-memory. A typical case when we can load the source is when the model comes from an artifact deployed in the controller, since we can read it from the jar as a resource.



 Comments   
Comment by Robert Varga [ 10/Nov/15 ]

Beryllium parser no longer retains sources, so this has been fixed.

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