summaryrefslogtreecommitdiffstats
path: root/intentanalysis
diff options
context:
space:
mode:
authorKeguang He <hekeguang@chinamobile.com>2022-08-31 03:41:52 +0000
committerGerrit Code Review <gerrit@onap.org>2022-08-31 03:41:52 +0000
commit037fadaa1c6385a5bfe525e1aec48cc65ec486ec (patch)
treea0484117576eaad6a7e0cbd92494b9e386b147b0 /intentanalysis
parent89c02e9c1b4328f68848fe4a6230d583089130b8 (diff)
parente3901c66783e3c0e5fff5878b43c0e1357c99da8 (diff)
Merge "[INTENT-ANALYSIS] Add policy models for bandwidth assurance intent"
Diffstat (limited to 'intentanalysis')
-rw-r--r--intentanalysis/src/main/resources/intentPolicy/deploy_intent_configs.json8
-rw-r--r--intentanalysis/src/main/resources/intentPolicy/deploy_modifycll.json9
-rw-r--r--intentanalysis/src/main/resources/intentPolicy/intent_configs_policy.json23
-rw-r--r--intentanalysis/src/main/resources/intentPolicy/intent_configs_policy_type.json28
-rw-r--r--intentanalysis/src/main/resources/intentPolicy/modifycll.json50
-rw-r--r--intentanalysis/src/test/resources/intentPolicy/deploy_intent_configs.json8
-rw-r--r--intentanalysis/src/test/resources/intentPolicy/deploy_modifycll.json9
-rw-r--r--intentanalysis/src/test/resources/intentPolicy/intent_configs_policy.json23
-rw-r--r--intentanalysis/src/test/resources/intentPolicy/intent_configs_policy_type.json28
-rw-r--r--intentanalysis/src/test/resources/intentPolicy/modifycll.json50
10 files changed, 236 insertions, 0 deletions
diff --git a/intentanalysis/src/main/resources/intentPolicy/deploy_intent_configs.json b/intentanalysis/src/main/resources/intentPolicy/deploy_intent_configs.json
new file mode 100644
index 0000000..1e22ce4
--- /dev/null
+++ b/intentanalysis/src/main/resources/intentPolicy/deploy_intent_configs.json
@@ -0,0 +1,8 @@
+{
+ "policies": [
+ {
+ "policy-id": "onap.dcae.slicems.config",
+ "policy-version": 1
+ }
+ ]
+}
diff --git a/intentanalysis/src/main/resources/intentPolicy/deploy_modifycll.json b/intentanalysis/src/main/resources/intentPolicy/deploy_modifycll.json
new file mode 100644
index 0000000..c8685cf
--- /dev/null
+++ b/intentanalysis/src/main/resources/intentPolicy/deploy_modifycll.json
@@ -0,0 +1,9 @@
+{
+ "policies":[
+ {
+ "policy-id":"operational.modifycll",
+ "policy-version":1
+ }
+ ]
+}
+
diff --git a/intentanalysis/src/main/resources/intentPolicy/intent_configs_policy.json b/intentanalysis/src/main/resources/intentPolicy/intent_configs_policy.json
new file mode 100644
index 0000000..a9d1e79
--- /dev/null
+++ b/intentanalysis/src/main/resources/intentPolicy/intent_configs_policy.json
@@ -0,0 +1,23 @@
+{
+ "tosca_definitions_version": "tosca_simple_yaml_1_1_0",
+ "topology_template": {
+ "policies": [
+ {
+ "onap.dcae.slicems.config": {
+ "type": "onap.policies.monitoring.docker.slicems.app",
+ "type_version": "1.0.0",
+ "version": "1.0.0",
+ "metadata": {
+ "policy-id": "onap.dcae.slicems.config",
+ "policy-version": 1
+ },
+ "properties": {
+ "cllId": "cll-01",
+ "closedLoopStatus": "on",
+ "originalBw": "1000"
+ }
+ }
+ }
+ ]
+ }
+}
diff --git a/intentanalysis/src/main/resources/intentPolicy/intent_configs_policy_type.json b/intentanalysis/src/main/resources/intentPolicy/intent_configs_policy_type.json
new file mode 100644
index 0000000..318b098
--- /dev/null
+++ b/intentanalysis/src/main/resources/intentPolicy/intent_configs_policy_type.json
@@ -0,0 +1,28 @@
+{
+ "tosca_definitions_version": "tosca_simple_yaml_1_1_0",
+ "policy_types": {
+ "onap.policies.monitoring.docker.slicems.app": {
+ "version": "1.0.0",
+ "description": "son handler policy type",
+ "derived_from": "onap.policies.Monitoring:1.0.0",
+ "description": "Runtime Configuration of Slice MS",
+ "properties": {
+ "cllId": {
+ "type": "string",
+ "required": true,
+ "description": "cll id"
+ },
+ "closedLoopStatus": {
+ "type": "string",
+ "required": true,
+ "description": "whether provide closed loop assurance for one cll"
+ },
+ "originalBw": {
+ "type": "string",
+ "required": true,
+ "description": "original bw of one cll"
+ }
+ }
+ }
+ }
+} \ No newline at end of file
diff --git a/intentanalysis/src/main/resources/intentPolicy/modifycll.json b/intentanalysis/src/main/resources/intentPolicy/modifycll.json
new file mode 100644
index 0000000..778a669
--- /dev/null
+++ b/intentanalysis/src/main/resources/intentPolicy/modifycll.json
@@ -0,0 +1,50 @@
+{
+
+ "tosca_definitions_version": "tosca_simple_yaml_1_1_0",
+ "topology_template": {
+ "policies": [
+ {
+ "operational.modifycll": {
+ "type": "onap.policies.controlloop.operational.common.Drools",
+ "type_version": "1.0.0",
+ "version": "1.0.0",
+ "name": "operational.modifycll",
+ "metadata": {
+ "policy_id": "operational.modifycll"
+ },
+ "properties": {
+ "id": "ControlLoop-CCVPN-CLL-227e8b00-dbeb-4d03-8719-d0a658fb846c",
+ "timeout": 1200,
+ "abatement": false,
+ "trigger": "unique-policy-id-1-modify-cll",
+ "operations": [
+ {
+ "id": "unique-policy-id-1-modify-cll",
+ "description": "Modify resource allocation for a slice subnet instance",
+ "operation": {
+ "actor": "SO",
+ "operation": "ModifyCloudLeasedLine",
+ "target": {
+ "targetType": "VNF"
+ }
+ },
+ "timeout": 1200,
+ "retries": 0,
+ "success": "final_success",
+ "failure": "final_failure",
+ "failure_timeout": "final_failure_timeout",
+ "failure_retries": "final_failure_retires",
+ "failure_exception": "final_failure_exception",
+ "failure_guard": "final_failure_guard"
+ }
+ ],
+ "controllerName": "usecases"
+ }
+
+ }
+
+ }
+ ]
+ }
+
+} \ No newline at end of file
diff --git a/intentanalysis/src/test/resources/intentPolicy/deploy_intent_configs.json b/intentanalysis/src/test/resources/intentPolicy/deploy_intent_configs.json
new file mode 100644
index 0000000..1e22ce4
--- /dev/null
+++ b/intentanalysis/src/test/resources/intentPolicy/deploy_intent_configs.json
@@ -0,0 +1,8 @@
+{
+ "policies": [
+ {
+ "policy-id": "onap.dcae.slicems.config",
+ "policy-version": 1
+ }
+ ]
+}
diff --git a/intentanalysis/src/test/resources/intentPolicy/deploy_modifycll.json b/intentanalysis/src/test/resources/intentPolicy/deploy_modifycll.json
new file mode 100644
index 0000000..c8685cf
--- /dev/null
+++ b/intentanalysis/src/test/resources/intentPolicy/deploy_modifycll.json
@@ -0,0 +1,9 @@
+{
+ "policies":[
+ {
+ "policy-id":"operational.modifycll",
+ "policy-version":1
+ }
+ ]
+}
+
diff --git a/intentanalysis/src/test/resources/intentPolicy/intent_configs_policy.json b/intentanalysis/src/test/resources/intentPolicy/intent_configs_policy.json
new file mode 100644
index 0000000..a9d1e79
--- /dev/null
+++ b/intentanalysis/src/test/resources/intentPolicy/intent_configs_policy.json
@@ -0,0 +1,23 @@
+{
+ "tosca_definitions_version": "tosca_simple_yaml_1_1_0",
+ "topology_template": {
+ "policies": [
+ {
+ "onap.dcae.slicems.config": {
+ "type": "onap.policies.monitoring.docker.slicems.app",
+ "type_version": "1.0.0",
+ "version": "1.0.0",
+ "metadata": {
+ "policy-id": "onap.dcae.slicems.config",
+ "policy-version": 1
+ },
+ "properties": {
+ "cllId": "cll-01",
+ "closedLoopStatus": "on",
+ "originalBw": "1000"
+ }
+ }
+ }
+ ]
+ }
+}
diff --git a/intentanalysis/src/test/resources/intentPolicy/intent_configs_policy_type.json b/intentanalysis/src/test/resources/intentPolicy/intent_configs_policy_type.json
new file mode 100644
index 0000000..318b098
--- /dev/null
+++ b/intentanalysis/src/test/resources/intentPolicy/intent_configs_policy_type.json
@@ -0,0 +1,28 @@
+{
+ "tosca_definitions_version": "tosca_simple_yaml_1_1_0",
+ "policy_types": {
+ "onap.policies.monitoring.docker.slicems.app": {
+ "version": "1.0.0",
+ "description": "son handler policy type",
+ "derived_from": "onap.policies.Monitoring:1.0.0",
+ "description": "Runtime Configuration of Slice MS",
+ "properties": {
+ "cllId": {
+ "type": "string",
+ "required": true,
+ "description": "cll id"
+ },
+ "closedLoopStatus": {
+ "type": "string",
+ "required": true,
+ "description": "whether provide closed loop assurance for one cll"
+ },
+ "originalBw": {
+ "type": "string",
+ "required": true,
+ "description": "original bw of one cll"
+ }
+ }
+ }
+ }
+} \ No newline at end of file
diff --git a/intentanalysis/src/test/resources/intentPolicy/modifycll.json b/intentanalysis/src/test/resources/intentPolicy/modifycll.json
new file mode 100644
index 0000000..778a669
--- /dev/null
+++ b/intentanalysis/src/test/resources/intentPolicy/modifycll.json
@@ -0,0 +1,50 @@
+{
+
+ "tosca_definitions_version": "tosca_simple_yaml_1_1_0",
+ "topology_template": {
+ "policies": [
+ {
+ "operational.modifycll": {
+ "type": "onap.policies.controlloop.operational.common.Drools",
+ "type_version": "1.0.0",
+ "version": "1.0.0",
+ "name": "operational.modifycll",
+ "metadata": {
+ "policy_id": "operational.modifycll"
+ },
+ "properties": {
+ "id": "ControlLoop-CCVPN-CLL-227e8b00-dbeb-4d03-8719-d0a658fb846c",
+ "timeout": 1200,
+ "abatement": false,
+ "trigger": "unique-policy-id-1-modify-cll",
+ "operations": [
+ {
+ "id": "unique-policy-id-1-modify-cll",
+ "description": "Modify resource allocation for a slice subnet instance",
+ "operation": {
+ "actor": "SO",
+ "operation": "ModifyCloudLeasedLine",
+ "target": {
+ "targetType": "VNF"
+ }
+ },
+ "timeout": 1200,
+ "retries": 0,
+ "success": "final_success",
+ "failure": "final_failure",
+ "failure_timeout": "final_failure_timeout",
+ "failure_retries": "final_failure_retires",
+ "failure_exception": "final_failure_exception",
+ "failure_guard": "final_failure_guard"
+ }
+ ],
+ "controllerName": "usecases"
+ }
+
+ }
+
+ }
+ ]
+ }
+
+} \ No newline at end of file