References
...
Proposed CM event |
---|
{ "eventId" : "9999", # some generic event uuid generated by DMI Plugin "event": { "push-change-update" : { "datastore-changes" : { {
} } } |
...
- NCMP is configured at startup with the cm subscription topic information (cm topic name, kafka addressing info).
Some app sends a 'CreateSubscription' event to the public cm subscription topic (cm-event-subscription).
Create Subscription : client app → ncmp Create Example {
"version": "<event type version>",
"eventType": "subscriptionCreated",
"event": {
"subscription": {
"clientID": "<unique identifier for the client >",
"name": "<unique subscription name per client>",
"isTagged": "<yes|no>, optional parameter, default is no"
},
"dataType": {
"dataspace": "<data space>",
"dataCategory": "<data category type>",
"dataProvider": "<data provider type>"
"schemaName": "<schema name>"
"schemaVersion": "<schema version>"
},
"predicates": {
"<parameter>": "<value>",
"param2": [
"value21",
"value22"
]}
}
}{
"version": "1.0",
"eventType": "subscriptionCreated",
"event": {
"subscription": {
"clientID": "SCO-9989752",
"name": "cm-subscription-001"
},
"dataType": {
"dataspace": "ALL",
"dataCategory": "CM",
"dataProvider": "CM-SERVICE"
"schemaName": "org.onap.ncmp.cm-notification-event"
"schemaVersion": "1.0"
},
"predicates": {
"datastore": “passthrough-operational",
"datastore-xpath-filter": "//_3gpp-nr-nrm-gnbdufunction:GNBDUFunction/
_3gpp-nr-nrm-nrcelldu:NRCellDU/ | //_3gpp-nr-nrm-gnbcuupfunction:GNBCUUPFunction// |
//_3gpp-nr-nrm-gnbcucpfunction:GNBCUCPFunction/_3gpp-nr-nrm-nrcelldu:NRCellCU// |
//_3gpp-nr-nrm-nrsectorcarrier:NRSectorCarrier//”}
}
}- NCMP receives consumes the create cm subscription event and processes it as follows :
- Persist the subscription and cm-subscription-filter information to db
- Read all CM handles that match the cm-filter-subscription (model matching, cmhandleId matching)
- If a subscription is already ongoing for a cmhandle then separate them from the list for later processing (after the existing ongoing cmhandle subscription has completed).
- Merge the existing cmhandle filter (if one exists from a previous subscription) with the new cm-filter-subscription
- Record the cmhandles whose existing cm subscription filter has been modified after filter merging in step c)
- For the cmhandle(s) with updates to their a new or modified subscription filter, group them according to their controlling dmi-plugin and send the one or more bulk subscription request(s) to the appropriate dmi-plugin(s).
- send the bulk subscription REST request to each dmi-plugin contains either a 'CreateSubscriptioncreate' (where no previous subscription exists on the cmhandle) or an 'UpdateSubscription' REST async update' subscription for each cmhandle
- the REST request to the dmi plugin managing the cmhandle(s). - The dmi plugins
...
- -plugin is asynchronous. The dmi-plugin shall process the each of the subscription requests per cmhandle and send an event only for cmhandles that fail to subscribe successfully.
Usecase | Protocol | Request Schema | Request Example |
---|---|---|---|
Register Subscriptions | <<REST>> ncmp → dmi | POST /ncmpInventory/v1/ |
subscriptions { |
cmhandleId" : " |
<cmhandle-id>", |
subscriptionType": " |
subscriptionCreated | subscriptionUpdated | subscriptionDeleted", |
existingSubscriptionId" : " |
<existing subscription-id on remote device>, optional, required for subscriptionUpdated | subscriptionDeleted", |
schemaName": " |
<schema name>, default is |
org.onap.ncmp.cm-notification-event", | POST /ncmpInventory/v1/subscriptions { |
cmhandleId" : " |
e34553", (M) |
}
{ |
5. dmi-plugin loops through the cmhandle subscriptions and creates a new subscription or modifies an existing subscription for the remote 'device' associated with the cmhandle.
6. dmi-plugin calls back to NCMP to notify of the newly created or updated subscription
7. NCMP updates its subscription registry with the new subscription information
Usecase | ||
---|---|---|
Notify of subscription request completion | <<event>> dmi → ncmp |
8.
Update Subscription
Topics
...