4ab910ba448ca980c0915dc14d09a2c7d52733e4
[policy/drools-applications.git] / controlloop / common / policy-yaml / src / test / resources / v1.0.0 / bad_trigger_1.yaml
1 # Copyright 2018 AT&T Intellectual Property. All rights reserved
2 #
3 # Licensed under the Apache License, Version 2.0 (the "License");
4 # you may not use this file except in compliance with the License.
5 # You may obtain a copy of the License at
6 #
7 #         http://www.apache.org/licenses/LICENSE-2.0
8 #
9 # Unless required by applicable law or agreed to in writing, software
10 # distributed under the License is distributed on an "AS IS" BASIS,
11 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 # See the License for the specific language governing permissions and
13 # limitations under the License.
14 controlLoop:
15   controlLoopName: ControlLoop-TEST-5dfa8fce-bd7a-4424-b60d-ee2ad2f254a3
16   version: 1.0.0
17   services: 
18     - serviceName: Foo Service
19   resources: 
20     - resourceName: Bar VNF
21       resourceType: VF
22   trigger_policy: FOO
23   timeout: 1200
24
25 policies:
26   - id: unique-policy-id-1-restart
27     name: Restart Policy for Trigger Event
28     description:
29     actor: APPC
30     recipe: Restart
31     target: VM
32     retry: 2
33     timeout: 300
34     success: unique-policy-id-2-healthcheck-restart
35     failure: unique-policy-id-3-rebuild
36     failure_timeout: unique-policy-id-3-rebuild
37     failure_retries: unique-policy-id-3-rebuild
38     failure_exception: final_failure_exception
39   
40   - id: unique-policy-id-2-healthcheck-restart
41     name: HealthCheck Policy
42     description:
43     actor: APPC
44     recipe: HealthCheck
45     target: VM
46     retry: 2
47     timeout: 300
48     success: final_success
49     failure: unique-policy-id-3-rebuild
50     failure_timeout: unique-policy-id-3-rebuild
51     failure_retries: unique-policy-id-3-rebuild
52     failure_exception: final_failure_exception
53   
54   - id: unique-policy-id-3-rebuild
55     name: Rebuild Policy
56     description:
57     actor: APPC
58     recipe: Rebuild
59     target: VM
60     retry: 0
61     timeout: 600
62     success: unique-policy-id-4-healthcheck-rebuild
63     failure: unique-policy-id-5-migrate
64     failure_timeout: unique-policy-id-5-migrate
65     failure_retries: unique-policy-id-5-migrate
66     failure_exception: final_failure_exception
67   
68   - id: unique-policy-id-4-healthcheck-rebuild
69     name: HealthCheck the Rebuild Policy
70     description:
71     actor: APPC
72     recipe: HealthCheck
73     target: VM
74     retry: 2
75     timeout: 300
76     success: final_success
77     failure: unique-policy-id-5-migrate
78     failure_timeout: unique-policy-id-5-migrate
79     failure_retries: unique-policy-id-5-migrate
80     failure_exception: final_failure_exception
81   
82   - id: unique-policy-id-5-migrate
83     name: Migrate Policy
84     description:
85     actor: APPC
86     recipe: Migrate
87     target: VM
88     retry: 0
89     timeout: 600
90     success: unique-policy-id-6-healthcheck-migrate
91     failure: final_failure
92     failure_timeout: final_failure_timeout
93     failure_retries: final_failure_retries
94     failure_exception: final_failure_exception
95
96   - id: unique-policy-id-6-healthcheck-migrate
97     name: Healthcheck the Migrate Policy
98     description:
99     actor: APPC
100     recipe: HealthCheck
101     target: VM
102     retry: 2
103     timeout: 300
104     success: final_success
105     failure: final_failure
106     failure_timeout: final_failure_timeout
107     failure_retries: final_failure_retries
108     failure_exception: final_failure_exception