Adding 'name' to yamls and json in model
[policy/models.git] / models-examples / src / main / resources / policies / vCPE.policies.optimization.input.tosca.yaml
1 tosca_definitions_version: tosca_simple_yaml_1_1_0
2 topology_template:
3   policies:
4     -
5         OSDF_CASABLANCA.Affinity_Default:
6             type: onap.policies.optimization.resource.AffinityPolicy
7             version: 1.0.0
8             type_version: 1.0.0
9             name: OSDF_CASABLANCA.Affinity_Default
10             metadata:
11                 policy-id: OSDF_CASABLANCA.Affinity_Default
12                 policy-version: 1
13             properties:
14                 scope: []
15                 services: []
16                 resources: []
17                 geography: []
18                 identity: affinity_vCPE
19                 applicableResources: any
20                 affinityProperties:
21                     qualifier: same
22                     category: complex
23     -
24         OSDF_CASABLANCA.Affinity_Default_US:
25             type: onap.policies.optimization.resource.AffinityPolicy
26             version: 1.0.0
27             type_version: 1.0.0
28             name: OSDF_CASABLANCA.Affinity_Default_US
29             metadata:
30                 policy-id: OSDF_CASABLANCA.Affinity_Default_US
31                 policy-version: 1
32             properties:
33                 scope: []
34                 services: []
35                 resources: []
36                 geography: [US]
37                 identity: affinity_vCPE
38                 applicableResources: any
39                 affinityProperties:
40                     qualifier: same
41                     category: complex
42     -
43         OSDF_CASABLANCA.Affinity_Default_vCPE_US_0:
44             type: onap.policies.optimization.resource.AffinityPolicy
45             version: 1.0.0
46             type_version: 1.0.0
47             name: OSDF_CASABLANCA.Affinity_Default_vCPE_US_0
48             metadata:
49                 policy-id: OSDF_CASABLANCA.Affinity_Default_vCPE_US_0
50                 policy-version: 1
51             properties:
52                 scope: []
53                 services: [vCPE]
54                 resources: []
55                 geography: [US]
56                 identity: affinity_vCPE
57                 applicableResources: any
58                 affinityProperties:
59                     qualifier: different
60                     category: complex
61     -
62         OSDF_CASABLANCA.Affinity_vCPE_US_Gold_1:
63             type: onap.policies.optimization.resource.AffinityPolicy
64             version: 1.0.0
65             type_version: 1.0.0
66             name: OSDF_CASABLANCA.Affinity_vCPE_US_Gold_1
67             metadata:
68                 policy-id: OSDF_CASABLANCA.Affinity_vCPE_1
69                 policy-version: 1
70             properties:
71                 scope: [gold]
72                 services: [vCPE]
73                 resources: [vGMuxInfra, vG]
74                 geography: [US, INTERNATIONAL]
75                 identity: affinity_vCPE
76                 applicableResources: any
77                 affinityProperties:
78                     qualifier: same
79                     category: availabilityZone
80     -
81         OSDF_CASABLANCA.Affinity_vCPE_US_Platinum_1:
82             type: onap.policies.optimization.resource.AffinityPolicy
83             version: 1.0.0
84             type_version: 1.0.0
85             name: OSDF_CASABLANCA.Affinity_vCPE_US_Platinum_1
86             metadata:
87                 policy-id: OSDF_CASABLANCA.Affinity_vCPE_1
88                 policy-version: 1
89             properties:
90                 scope: [platinum]
91                 services: [vCPE]
92                 resources: [vGMuxInfra, vG]
93                 geography: [US, INTERNATIONAL]
94                 identity: affinity_vCPE
95                 applicableResources: any
96                 affinityProperties:
97                     qualifier: different
98                     category: availabilityZone
99     -
100         OSDF_CASABLANCA.Capacity_vG_1:
101             type: onap.policies.optimization.resource.Vim_fit
102             version: 1.0.0
103             type_version: 1.0.0
104             name: OSDF_CASABLANCA.Capacity_vG_1
105             metadata:
106                 policy-id: OSDF_CASABLANCA.Capacity_vG_1
107                 policy-version: 1
108             properties:
109                 scope: []
110                 services: [vCPE]
111                 resources: [vG]
112                 geography: [US, INTERNATIONAL]
113                 identity: capacity_vG
114                 applicableResources: any
115                 capacityProperty:
116                    controller: multicloud
117                    request: "{\"vCPU\": 10, \"Memory\": {\"quantity\": {\"get_param\": \"REQUIRED_MEM\"}, \"unit\": \"GB\"}, \"Storage\": {\"quantity\": {\"get_param\": \"REQUIRED_DISK\"}, \"unit\": \"GB\"}}"
118     -
119         OSDF_CASABLANCA.Capacity_vG_2:
120             type: onap.policies.optimization.resource.Vim_fit
121             version: 1.0.0
122             type_version: 1.0.0
123             name: OSDF_CASABLANCA.Capacity_vG_2
124             metadata:
125                 policy-id: OSDF_CASABLANCA.Capacity_vG_2
126                 policy-version: 1
127             properties:
128                 scope: []
129                 services: [vCPE]
130                 resources: [vG]
131                 geography: [US, INTERNATIONAL]
132                 identity: capacity_vG
133                 applicableResources: any
134                 capacityProperty:
135                    controller: multicloud
136                    request: "{\"vCPU\": 15, \"Memory\": {\"quantity\": {\"get_param\": \"REQUIRED_MEM\"}, \"unit\": \"MB\"}, \"Storage\": {\"quantity\": {\"get_param\": \"REQUIRED_DISK\"}, \"unit\": \"GB\"}}"
137     -
138         OSDF_CASABLANCA.Distance_vG_1:
139             type: onap.policies.optimization.resource.DistancePolicy
140             version: 1.0.0
141             type_version: 1.0.0
142             name: OSDF_CASABLANCA.Distance_vG_1
143             metadata:
144                 policy-id: OSDF_CASABLANCA.Distance_vG_1
145                 policy-version: 1
146             properties:
147                 scope: [platinum]
148                 services: [vCPE]
149                 resources: [vG]
150                 geography: [US, INTERNATIONAL]
151                 identity: distance-vG
152                 applicableResources: any
153                 distanceProperties:
154                     locationInfo: customer_loc
155                     distance:
156                         value: 1500
157                         operator: "<"
158                         unit: km
159     -
160         OSDF_CASABLANCA.hpa_policy_Default:
161             type: onap.policies.optimization.resource.HpaPolicy
162             version: 1.0.0
163             type_version: 1.0.0
164             name: OSDF_CASABLANCA.hpa_policy_Default
165             metadata:
166                 policy-id: OSDF_CASABLANCA.hpa_policy_Default
167                 policy-version: 1
168             properties:
169                 scope: []
170                 services: []
171                 resources: []
172                 geography: []
173                 identity: hpa-vG
174                 flavorFeatures:
175                     -
176                          id: vg_1
177                          type: vnfc
178                          directives:
179                              -    type: flavor_directives
180                                   attributes:
181                                       -    attribute_name: flavor_label_vm_01
182                                            attribute_value: ""
183                          flavorProperties:
184                              -
185                                   hpa-feature: basicCapabilities
186                                   mandatory: True
187                                   architecture: generic
188                                   directives: []
189                                   hpa-feature-attributes:
190                                       -    hpa-attribute-key: numVirtualCpu
191                                            hpa-attribute-value: 8
192                                            operator: ['>=']
193                                            unit: ""
194                                       -    hpa-attribute-key: virtualMemSize
195                                            hpa-attribute-value: 6
196                                            operator: ['<=']
197                                            unit: ""
198                              -
199                                   hpa-feature: ovsDpdk
200                                   mandatory: False
201                                   architecture: generic
202                                   directives: []
203                                   hpa-feature-attributes:
204                                       -    hpa-attribute-key: dataProcessingAccelerationLibrary
205                                            hpa-attribute-value: ovsDpdk_version
206                                            operator: [=]
207                                            unit: ""
208     -
209         OSDF_CASABLANCA.hpa_policy_vG_1:
210             type: onap.policies.optimization.resource.HpaPolicy
211             version: 1.0.0
212             type_version: 1.0.0
213             name: OSDF_CASABLANCA.hpa_policy_vG_1
214             metadata:
215                 policy-id: OSDF_CASABLANCA.hpa_policy_vG_1
216                 policy-version: 1
217             properties:
218                 scope: []
219                 services: [vCPE, vOtherService]
220                 resources: [vG]
221                 geography: []
222                 identity: hpa-vG
223                 flavorFeatures:
224                     -
225                          id: vg_1
226                          type: vnfc
227                          directives:
228                              -    type: flavor_directives
229                                   attributes:
230                                       -    attribute_name: flavor_label_vm_01
231                                            attribute_value: ""
232                          flavorProperties:
233                              -
234                                   hpa-feature: basicCapabilities
235                                   mandatory: True
236                                   architecture: generic
237                                   directives: []
238                                   hpa-feature-attributes:
239                                       -    hpa-attribute-key: numVirtualCpu
240                                            hpa-attribute-value: 6
241                                            operator: ['>=']
242                                            unit: ""
243                                       -    hpa-attribute-key: virtualMemSize
244                                            hpa-attribute-value: 4
245                                            operator: ['<=']
246                                            unit: ""
247                              -
248                                   hpa-feature: ovsDpdk
249                                   mandatory: False
250                                   architecture: generic
251                                   directives: []
252                                   hpa-feature-attributes:
253                                       -    hpa-attribute-key: dataProcessingAccelerationLibrary
254                                            hpa-attribute-value: ovsDpdk_version
255                                            operator: [=]
256                                            unit: ""
257     -
258         OSDF_CASABLANCA.queryPolicy_vCPE:
259             type: onap.policies.optimization.service.QueryPolicy
260             version: 1.0.0
261             type_version: 1.0.0
262             name: OSDF_CASABLANCA.queryPolicy_vCPE
263             metadata:
264                 policy-id: OSDF_CASABLANCA.queryPolicy_vCPE
265                 policy-version: 1
266             properties:
267                 scope: []
268                 services: [vCPE]
269                 geography: [US, INTERNATIONAL]
270                 identity: vCPE_Query_Policy
271                 queryProperties:
272                     -
273                         attribute: locationId
274                         attribute_location: customerLocation
275                         value: ""
276                     -
277                         attribute: id
278                         attribute_location: "vpnInfo.vpnId"
279                         value: ""
280                     -
281                         attribute: upstreamBW
282                         attribute_location: "vpnInfo.upstreamBW"
283                         value: ""
284                     -
285                         attribute: customerLatitude
286                         attribute_location: customerLatitude
287                         value: 1.1
288                     - 
289                         attribute: customerLongitude
290                         attribute_location: customerLongitude
291                         value: 2.2
292     -
293         OSDF_CASABLANCA.SubscriberPolicy_v1:
294             type: onap.policies.optimization.service.SubscriberPolicy
295             version: 1.0.0
296             type_version: 1.0.0
297             name: OSDF_CASABLANCA.SubscriberPolicy_v1
298             metadata:
299                 policy-id: OSDF_CASABLANCA.SubscriberPolicy_v1
300                 policy-version: 1
301             properties:
302                 scope: []
303                 services: [vCPE]
304                 identity: subscriber_vCPE
305                 subscriberProperties:
306                     subscriberName: [subscriber_x, subscriber_y]
307                     subscriberRole: [platinum]
308                     provStatus: [CAPPED]
309     -
310         OSDF_CASABLANCA.SubscriberPolicy_v2:
311             type: onap.policies.optimization.service.SubscriberPolicy
312             version: 1.0.0
313             type_version: 1.0.0
314             name: OSDF_CASABLANCA.SubscriberPolicy_v2
315             metadata:
316                 policy-id: OSDF_CASABLANCA.SubscriberPolicy_v2
317                 policy-version: 1
318             properties:
319                 scope: []
320                 services: [vCPE]
321                 identity: subscriber_vCPE
322                 subscriberProperties:
323                     subscriberName: [subscriber_a, subscriber_b]
324                     subscriberRole: [gold]
325                     provStatus: [CAPPED]
326     -
327         OSDF_CASABLANCA.vnfPolicy_vG:
328             type: onap.policies.optimization.resource.VnfPolicy
329             version: 1.0.0
330             type_version: 1.0.0
331             name: OSDF_CASABLANCA.vnfPolicy_vG
332             metadata:
333                 policy-id: OSDF_CASABLANCA.vnfPolicy_vG
334                 policy-version: 1
335             properties:
336                 scope: []
337                 services: [vCPE]
338                 resources: [vG]
339                 geography: [US, INTERNATIONAL]
340                 identity: vnf_vG
341                 applicableResources: any
342                 vnfProperties:
343                     -
344                         inventoryProvider: aai
345                         serviceType: ""
346                         inventoryType: cloudRegionId
347                         customerId: ""