...
This is actually a blueprint for PM use case with some modifications.
The setup can be verified by making a manual REST request on CDS.
Code Block | ||||||
---|---|---|---|---|---|---|
| ||||||
curl -X POST 'http://<ip>:<port>/api/v1/execution-service/process' \
-H 'Content-Type: application/json' \
-H 'Authorization: Basic Y2NzZGthcHBzOmNjc2RrYXBwcw==' \
-d '{
"actionIdentifiers": {
"actionName": "create-subscription",
"blueprintName": "pm_control",
"blueprintVersion": "1.0.0",
"mode": "sync"
},
"commonHeader": {
"originatorId": "sdnc",
"requestId": "123456-1000",
"subRequestId": "sub-123456-1000"
},
"payload": {
"create-subscription-request": {
"create-subscription-properties": {
"nfName": "<pnf_name>",
"subscriptionName": "demo-subscription",
"administrativeState": "UNLOCKED",
"fileBasedGP": "15",
"fileLocation": "test/pm.xml"
}
}
}
}' |
Drools Tosca Policy to test CDS interaction for PNF:
...
Code Block | ||||||
---|---|---|---|---|---|---|
| ||||||
commonHeader { timestamp: "2020-05-06T16:43:32.437Z" requestId: "c7c6a4aa-bb61-4a15-b831-ba1472dd4a56" subRequestId: "0" flag { } originatorId: "POLICY" } actionIdentifiers { blueprintName: "pm_control" blueprintVersion: "1.0.0" actionName: "create-subscription" mode: "sync" } status { code: 200 message: "success" eventType: EVENT_COMPONENT_EXECUTED timestamp: "Wed May 06 16:43:33 GMT 2020" } payload { fields { key: "create-subscription-response" value { struct_value { fields { key: "odl-response" value { struct_value { fields { key: "status" value { string_value: "success" } } } } } } } } } |