...
DMaaP offers a client plugin called DMaaP Client, which can be found here. This Client can be used to register to a DMaaP event. The PoC code will use this client to show that CPS can listen for and receive DMaaP events.
Example of DMaaP Event when a pnf is added to A&AI:
Code Block | ||||||
---|---|---|---|---|---|---|
| ||||||
{"cambria.partition":"AAI",
"event-header":{
"severity":"NORMAL",
"entity-type":"pnf",
"top-entity-type":"pnf",
"entity-link":"/aai/v23/network/pnfs/pnf/dummyTest30",
"event-type":"AAI-EVENT",
"domain":"dev",
"action":"CREATE",
"sequence-number":"0","id":"577eb229-7c74-4cf8-84ab-79f66f4899b2",
"source-name":"SO",
"version":"v23",
"timestamp":"20210701-12:45:09:351"
},
"entity":{
"ipaddress-v4-oam":"100.10.20.20",
"equip-type":"example-equip-type-val-20348",
"equip-vendor":"example-equip-vendor-val-52182",
"ipaddress-v6-oam":"",
"orchestration-status":"Active",
"pnf-name2":"dummypnf-1597953056126",
"equip-model":"example-equip-model-val-8370",
"in-maint":false,
"resource-version":"1625143508438",
"pnf-id":"927b2580-36d9-4f13-8421-3c9d43b7a75e",
"management-option":"example-management-option-val-72881",
"spare-equipment-indicator":false,
"pnf-name":"dummyTest30"}
} |
Proof Of Concept Code:
To use the DMaaP Client we need the following dependency in our pom.xml file.
...