[YANGTOOLS-980] Expand DataSchemaContextTree capabilities Created: 30/Mar/19  Updated: 22/Dec/23

Status: Confirmed
Project: yangtools
Component/s: data-util
Affects Version/s: None
Fix Version/s: 14.0.0

Type: Improvement Priority: Medium
Reporter: Robert Varga Assignee: Unassigned
Resolution: Unresolved Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Relates
relates to YANGTOOLS-1259 Split out immutable NormalizedNode im... Resolved

 Description   

DataSchemaContextTree provides binding between SchemaContext (i.e. effective schema tree) and NormalizedNodes (data tree instantiation), with the current capabilities being limited to walking the trees based either

There are a number of optimizations we can make to NormalizedNodes based on either tree, but since the tree mostly interacts with data, there is a number of services it could provide.

The most notable is an improved version of LeafInterner - unlike the current versions, which needs to be quick, we could spend some time to examine the characteristics of the LeafSchemaNode type to determine whether to intern it - like limited ranges, etc.

It would also be nice to provide proper validation services, such as mandatory node enforcement though we need to differentiate between full validation and incremental validation. The former is useful when a NormalizedNode tree meets a schema-aware component, the latter is useful when a NormalizedNode tree is being built up.

Furtheremore we should consider a capability to trim/introduce LeafNodes and LeafListNodes with default values – so that we can perform proper transformations, either via NormalizedNode reconstitution or via streaming translation (both layered on tom DataSchemaContextTree).

Note this includes evaluation of when/must statements, which opens up it to a quite a chunk of work hence this issue should be analyzed and broken down into reasonable deliverables.

One thing that should be addressed in the first iteration is the use of concurrent maps in DataContainerContextNode.

 


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