Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Below is example of schema-mount data set JSON referencing model to be taken from a library:

Code Block
titleschema-mount.json
{
  "ietf-yang-schema-mount:schema-mounts": {
    "mount-point": [{
        "module": "test-mount",
        "label": "root-mp",
        "shared-schema": {}
       }]
  }
}


Addressing mounted modules

Mounted model can be addressed the one of the following ways:

...

draw.io Diagram
borderfalse
diagramNamecps-yang-mount-dependencies-diagram
simpleViewerfalse
linksauto
tbstyleinline
lboxfalse
diagramWidth631
revision2


Embedded reference

The reference to mounted module could be embedded directly into mount point and delivered together with a data.
The mounted module reference is expected to be described as ietf-yang-library component

Code Block
titleschema-mount.json
{
  "ietf-yang-schema-mount:schema-mounts": {
    "mount-point": [{
        "module": "test-mount",
        "label": "root-mp",
        "inline": {}
       }]
  }
}

The data then will look like below

Code Block
titledata-referencing-mounted-module-inline.json
{
  "test-mount:root-element": { 
    "root-mp": { // mount point
	   "ietf-yang-library:modules-state": { // mounted module (and dependencies) descriptor
          "module-set-id": "some-id",
          "module": [{
               "name": "mounted-module",
               "revision": "2020-02-02",
               "namespace": "urn:org:onap:cps:test:mounted-module",
               "conformance-type": "import"
            }
            // other modules
            ]
	    },
        "mounted-module:mounted-container": { // actual mounted module data
			// data associated to mounted module
		}
    }
  }
}


Implementation Approach in a Context of CPS

...