...
Field | R/O | Type | Description |
---|---|---|---|
ONAPName | R | String | Name of the ONAP Project that is making the request. |
ONAPComponent | O | String | Name of the ONAP Project component that is making the request. |
ONAPInstance | O | String | Optional instance identification for that ONAP component. |
action | R | String | The action that the ONAP component is performing on a resource. eg. "configure" → DCAE uS onap.Monitoring policy Decisions to configure uS "naming" "placement" "guard" |
These sub metadata structures are used to refine which resource the ONAP component is performing an action upon. At least one is required in order for Policy to return a Decision. Multiple structures may be utilized to help refine a Decision. | |||
policy-type-name | String | The policy type name. This may be a regular expression. | |
policy-id | String | The policy id. This may be a regular expression or an exact value. | |
...
Code Block | ||||
---|---|---|---|---|
| ||||
{ "ONAPName": "DCAE", "ONAPComponent": "PolicyHandler", "ONAPInstance": "policy-handler-0UUID", "action": "configure", "resource": { "policy-id": "onap.scaleout" } } |
...
Code Block | ||||||
---|---|---|---|---|---|---|
| ||||||
{ "policies": { "onap.scaleoutvcpe.tca": { "type": "onap.policies.monitoring.cdap.tca.hi.lo.app", "version": "1.0.0", "metadata": { "policy-id": "onap.scaleoutvcpe.tca", "policy-version": 1 }, "properties": { "domain": "measurementsForVfScaling" } }, "onap.modifyconfig": { "type": "onap.policies.monitoring.cdap.tca.hi.lo.app", "version": "1.0.0", "metadata": { "policy-id": "onap.modifyconfig", "policy-version": 1 }, "properties": { "domain": "measurementsForVfScaling" } }, "onap.restart": { "type": "onap.policies.monitoring.cdap.tca.hi.lo.app", "version": "1.0.0", "metadata": { "policy-id": "onap.restart", "policy-version": 1 }, "properties": { "domain": "measurementsForVfScaling" } } } } |
This example below shows the JSON body of a query for a multiple policy-id's
...
Code Block | ||||
---|---|---|---|---|
| ||||
{ "ONAPName": "DCAE", "ONAPInstance": "policy-handler-0", "action": "configure", "resource": { "policy-id": [ "onap.vcpe.tca", "action "onap.modifyconfig", "onap.restart" ] } } |
Code Block | ||||||
---|---|---|---|---|---|---|
| ||||||
{ "policies": { "onap.vcpe.tca": { "type": "onap.policies.monitoring.cdap.tca.hi.lo.app", "version": "configure1.0.0", "resource "metadata": { "policy-id": [ "onap.scaleoutvcpe.tca", "onap.modifyconfig", "onap.restart" ] } } | ||||||
Code Block | ||||||
| ||||||
{ "policies": [ { "onap.scaleout.tca": { policy-version": 1 }, "properties": { "domain": "measurementsForVfScaling" } }, "onap.modifyconfig": { "type": "onap.policies.monitoring.cdap.tca.hi.lo.app", "version": "1.0.0", "metadata": { "policy-id": "onap.scaleout.tcamodifyconfig", "policy-version": 1 }, "properties": { "domain": "measurementsForVfScaling" <OMITTED FOR BREVITY> } } }, { "onap.firewall.tcarestart": { "type": "onap.policies.monitoring.cdap.tca.hi.lo.app", "version": "1.0.0", "metadata": { "policy-id": "onap.firewall.tcarestart", "policy-version": 1 }, "properties": { "domain": "measurementsForVfScaling" <OMITTED FOR BREVITY> } } } } } ] } |
The simple draft example below shows the JSON body of a query in which all the deployed policies for a specific policy type are returned.
...