Transformer Infra support for sonic yang structure deviations from flattened structure - sibling list to singleton container and nested list#129
Merged
kwangsuk merged 12 commits intosonic-net:masterfrom Apr 24, 2024
Conversation
…LETE flow b)modified DELETE flow to support sibling list to singleton container
… utilities b)modified GET flow to support sibling list to singleton container
Before adding default value to result map, check if result map already has the field and add only if not present
- Check for fillFields fields in resultMap for field delete case.
- do not create table entry with NULL/NULL attribute when there are defaults from the translated result to be configutetd alongside for OC yang also
…gleton container and list and a nested list table
…f github.com:amrutasali/sonic-mgmt-common into transformer_infra_handling_for_sonic_yang_deviations
…nd nested-list DELETE cases
|
@anand-kumar-subramanian @sachinholla pls help review the change |
anand-kumar-subramanian
previously approved these changes
Apr 3, 2024
kwangsuk
previously approved these changes
Apr 3, 2024
…as the CVL changes are in review and ready to be merged
b4a8efe
…f github.com:amrutasali/sonic-mgmt-common into transformer_infra_handling_for_sonic_yang_deviations
Contributor
|
@anand-kumar-subramanian Please can you re-review this PR. The CVL changes are pulled in and tested in this PR. |
kwangsuk
approved these changes
Apr 8, 2024
Contributor
Author
|
Ping @faraazbrcm @sachinholla @anand-kumar-subramanian |
faraazbrcm
approved these changes
Apr 22, 2024
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What we did:
1.) Added support in transformer infra to handle nested list under a list which is an immediate child of table level container in Sonic Yang. This satisfies the dynmic fields in DB case.eg. https://github.com/sonic-net/sonic-buildimage/blob/master/src/sonic-yang-models/yang-models/sonic-cable-length.yang#L40
2.) Sibling list to singleton container eg. https://github.com/sonic-net/sonic-buildimage/blob/master/src/sonic-yang-models/yang-models/sonic-telemetry_client.yang#L89C12-L89C30
Why we did it?
To allow applications using the above mentioned sonic yang structures to make configurations and retrieval of DB data via mgmt-framework when sonic yang is used as NBI.
How did we verify the changes?
Verification done using unit tests on transformer test yang and added new cases for above.
Unit test run results are part of pipeline test run.
Note :The pipeline run of this PR to be successful is dependent on PR - to be merged first.