summaryrefslogtreecommitdiffstats
path: root/controlloop/common/policy-yaml/src/test/resources
diff options
context:
space:
mode:
Diffstat (limited to 'controlloop/common/policy-yaml/src/test/resources')
-rw-r--r--controlloop/common/policy-yaml/src/test/resources/v2.0.0-guard/policy_guard_ONAP_demo_vDNS.yaml19
-rw-r--r--controlloop/common/policy-yaml/src/test/resources/v2.0.0-guard/policy_guard_OpenECOMP_demo_vDNS.yaml14
-rw-r--r--controlloop/common/policy-yaml/src/test/resources/v2.0.0-guard/policy_guard_OpenECOMP_demo_vDNS.yaml~12
-rw-r--r--controlloop/common/policy-yaml/src/test/resources/v2.0.0-guard/policy_guard_appc_restart.yaml24
-rw-r--r--controlloop/common/policy-yaml/src/test/resources/v2.0.0-guard/policy_guard_vUSP_1707_appc.yaml26
5 files changed, 43 insertions, 52 deletions
diff --git a/controlloop/common/policy-yaml/src/test/resources/v2.0.0-guard/policy_guard_ONAP_demo_vDNS.yaml b/controlloop/common/policy-yaml/src/test/resources/v2.0.0-guard/policy_guard_ONAP_demo_vDNS.yaml
new file mode 100644
index 000000000..f2390fae0
--- /dev/null
+++ b/controlloop/common/policy-yaml/src/test/resources/v2.0.0-guard/policy_guard_ONAP_demo_vDNS.yaml
@@ -0,0 +1,19 @@
+guard:
+ version: 2.0.0
+
+guards:
+ - id: unique_guard_ONAP_vDNS_1
+ name: MSO Spinup
+ description: We only spin up 1 instance over a 10 minute window
+ match_parameters:
+ actor: MSO
+ recipe: VF Module Create
+ limit_constraints:
+ - freq_limit_per_target: 1
+ #
+ # https://www.w3.org/TR/xmlschema-2/#duration
+ #
+ time_window:
+ value: 10
+ units: hour
+ \ No newline at end of file
diff --git a/controlloop/common/policy-yaml/src/test/resources/v2.0.0-guard/policy_guard_OpenECOMP_demo_vDNS.yaml b/controlloop/common/policy-yaml/src/test/resources/v2.0.0-guard/policy_guard_OpenECOMP_demo_vDNS.yaml
deleted file mode 100644
index 7b5f17c61..000000000
--- a/controlloop/common/policy-yaml/src/test/resources/v2.0.0-guard/policy_guard_OpenECOMP_demo_vDNS.yaml
+++ /dev/null
@@ -1,14 +0,0 @@
-guard:
- version: 2.0.0
-
-guards:
- - id: unique_guard_ONAP_vDNS_1
- name: MSO Spinup
- description: We only spin up 1 instance over a 10 minute window
- actor: MSO
- recipe: VF Module Create
- limit_constraints:
- - num: 1
- duration:
- value: 15
- units: minute
diff --git a/controlloop/common/policy-yaml/src/test/resources/v2.0.0-guard/policy_guard_OpenECOMP_demo_vDNS.yaml~ b/controlloop/common/policy-yaml/src/test/resources/v2.0.0-guard/policy_guard_OpenECOMP_demo_vDNS.yaml~
deleted file mode 100644
index a0d76d225..000000000
--- a/controlloop/common/policy-yaml/src/test/resources/v2.0.0-guard/policy_guard_OpenECOMP_demo_vDNS.yaml~
+++ /dev/null
@@ -1,12 +0,0 @@
-guard:
- version: 2.0.0
-
-guards:
- - id: unique_guard_ONAP_vDNS_1
- name: MSO Spinup
- description: We only spin up 1 instance over a 10 minute window
- actor: MSO
- recipe: VF Module Create
- limit_constraints:
- - num: 1
- duration: PT10M
diff --git a/controlloop/common/policy-yaml/src/test/resources/v2.0.0-guard/policy_guard_appc_restart.yaml b/controlloop/common/policy-yaml/src/test/resources/v2.0.0-guard/policy_guard_appc_restart.yaml
new file mode 100644
index 000000000..6e47ca2b4
--- /dev/null
+++ b/controlloop/common/policy-yaml/src/test/resources/v2.0.0-guard/policy_guard_appc_restart.yaml
@@ -0,0 +1,24 @@
+guard:
+ version: 2.0.0
+
+guards:
+ - id: unique_guard_1
+ name: APPC 5 Restart
+ description:
+ We only allow 5 restarts over 15 minute window during the day time hours (i.e. avoid midnight to 5am)
+ match_parameters:
+ controlLoopName: CL_NAME_ABC_123
+ actor: APPC
+ recipe: Restart
+ targets:
+ - s1
+ s2
+ s3
+ limit_constraints:
+ - freq_limit_per_target: 5
+ time_window:
+ value: 15
+ units: minute
+ active_time_range:
+ start: 00:00:00-05:00
+ end: 23:59:59-05:00 \ No newline at end of file
diff --git a/controlloop/common/policy-yaml/src/test/resources/v2.0.0-guard/policy_guard_vUSP_1707_appc.yaml b/controlloop/common/policy-yaml/src/test/resources/v2.0.0-guard/policy_guard_vUSP_1707_appc.yaml
deleted file mode 100644
index a487210cd..000000000
--- a/controlloop/common/policy-yaml/src/test/resources/v2.0.0-guard/policy_guard_vUSP_1707_appc.yaml
+++ /dev/null
@@ -1,26 +0,0 @@
-guard:
- version: 2.0.0
-
-guards:
- - id: unique_guard_vUSP_1
- name: APPC 5 Restart
- description:
- We only allow 5 restarts over 15 minute window during the day time hours (i.e. avoid midnight to 5am)
- actor: APPC
- recipe: Restart
- limit_constraints:
- - num: 5
- #
- # https://www.w3.org/TR/xmlschema-2/#duration
- #
- duration:
- value: 15
- units: minute
- #
- # XACML function time-in-range
- #
- # Assumption is that the "current time" is the 1st argument
- #
- time_in_range:
- arg2: PT5H
- arg3: PT24H \ No newline at end of file