Versions Compared

Key

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

...

...

...

...

...

...

...

...

...

...

Table of Contents

References

Jira Legacy
serverONAP System Jira
serverId425b2b0a4733707d-557c2057-3c0c3a0f-b515ae5e-579789cceedb4fd8aff50176
keyCPS-677

Issues/Decisions

#IssueNotesDecision
1removing public property using update with 'null' should also be possible for additional properties
Have separate user story for property 'removal' that will handle both cases 9as sub tasks if need).
Changes are most of code will be similar for each

Scope

  • Support should include create/delete/update from a dmi plugin.

...

Requirement URI
Comment

NCMP-008

Register or update public cmhandle properties


{ncmpRoot}/ncmpncmpInventory/v1/ch/
Scenario : DMI notifies NCMP of new, updated or removed cmhandles
Method : POST
URI : {ncmpRoot}/ncmpncmpInventory/v1/ch/
Header :
Content-Type: application/json


Request Body

Request Body : {
      "dmiPlugin" : "onap.dmi.plugin",
      "createdCmHandles" : [ {   "cmHandle" : "rf4er5454",
                                 "cmHandleProperties" : {
                                    "samplePropertyName1" : "samplePropertyValue1"
                                  }        

                                                                         "publicCmHandleProperties" :  {     
                                                                                "hostedBy" : "cmhandle-5678"                                                                                       
                                                                                 "samplePropertyName2" : "samplePropertyValue2

                                  }

                             },
                             {..}
                           ],

      "updatedCmHandles" : [
                             {

                                 "cmHandle" : "ds4errr77",
                                 "cmHandleProperties" : { # To remove a property, set the value to "NULL"null
                                    "samplePropertyName1" : "updatedSamplePropertyValue1",
                                    "samplePropertyName2" : "NULL"  null  # This property will be removed
                                  }        

                                                                         "publicCmHandleProperties" :  {      # To remove a property, set the value to "NULL"null
                                                                               "hostedBy" : "cmhandle-11213",
                                                                                "samplePublicPropertyName1" : "updatedSamplePublicPropertyValue2"

                                  }


                             },
                             {..}

                           ],
      "removedCmHandles" : [ "node-1", "node-2" , ... ]
  }


json attributes:

  • "dmiPlugin" resolvable servicename
  • "createdCmHandles" used for initial cm handle registrations or subsequent
    cmhandle creations
  • "updatedCmHandles"
    Used for updates to cmhandles. Same structure as for create handles
  • "removedCmHandles"  array of cmhandles that have been deleted
    from the network (no additional properties
  1. Is the URI being updated to {ncmpRoot}/ncmpDmi/v2/ch ?
  2. Update to an existing interface
  3. New proposed additions in red
  4. To remove a property, suggest to set the value for the property to "NULL" json null in the updatedCmHandles section
  5. Note, the given properties like hostedBy are sample data only.

...

Code Block
themeEmacs
titleDecember 2021 Yang Model
linenumberstruecollapsetrue
module dmi-registry {

  yang-version 1.1;

  namespace \"org:onap:cps:ncmp\";

  prefix dmi-reg;

  organization \"Nordix Foundation\";

  contact \"rahul.tyagi@est.tech\";

  revision \"2021-12-13\" {
   description
   \"Added support for new list of public additional properties for a Cm-Handle which are exposed to clients of the NCMP interface. \";
  }

  container dmi-registry {

    list cm-handles {

      key \"id\";

      leaf id {
        type string;
      }

      leaf dmi-service-name {
        type string;
      }

      leaf dmi-data-service-name {
        type string;
      }

      leaf dmi-model-service-name {
        type string;
      }

      list additional-properties {
        key \"name\";
        leaf name {
          type string;
        }
        leaf value {
          type string;
        }
      }
      list public-properties {
        key \"name\";
        leaf name {
          type string;
        }
        leaf value {
          type string;
        }
      }
    }
  }
}  

...