e979aec1a3a97c0107428c090f4fda60c2318758
[osm/LCM.git] / osm_lcm / tests / test_db_descriptors.py
1 #
2 # Licensed under the Apache License, Version 2.0 (the "License"); you may
3 # not use this file except in compliance with the License. You may obtain
4 # a copy of the License at
5 #
6 # http://www.apache.org/licenses/LICENSE-2.0
7 #
8 # Unless required by applicable law or agreed to in writing, software
9 # distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
10 # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
11 # License for the specific language governing permissions and limitations
12 # under the License.
13 #
14 # For those usages not covered by the Apache License, Version 2.0 please
15 # contact: esousa@whitestack.com or alfonso.tiernosepulveda@telefonica.com
16 ##
17 db_nsds_text = """
18 ---
19 - _admin:
20 created: 1566823353.971486
21 modified: 1566823353.971486
22 onboardingState: ONBOARDED
23 operationalState: ENABLED
24 projects_read:
25 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
26 projects_write:
27 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
28 storage:
29 descriptor: hackfest_3charmed_nsd/hackfest_3charmed_nsd.yaml
30 folder: 8c2f8b95-bb1b-47ee-8001-36dc090678da
31 fs: local
32 path: /app/storage/
33 pkg-dir: hackfest_3charmed_nsd
34 zipfile: package.tar.gz
35 usageState: NOT_IN_USE
36 userDefinedData: {}
37 _id: 8c2f8b95-bb1b-47ee-8001-36dc090678da
38 constituent-vnfd:
39 - member-vnf-index: '1'
40 vnfd-id-ref: hackfest3charmed-vnf
41 - member-vnf-index: '2'
42 vnfd-id-ref: hackfest3charmed-vnf
43 description: NS with 2 VNFs hackfest3charmed-vnf connected by datanet and mgmtnet
44 VLs
45 id: hackfest3charmed-ns
46 logo: osm.png
47 name: hackfest3charmed-ns
48 short-name: hackfest3charmed-ns
49 version: '1.0'
50 vld:
51 - id: mgmt
52 mgmt-network: true
53 name: mgmt
54 short-name: mgmt
55 type: ELAN
56 vim-network-name: mgmt
57 vnfd-connection-point-ref:
58 - member-vnf-index-ref: '1'
59 vnfd-connection-point-ref: vnf-mgmt
60 vnfd-id-ref: hackfest3charmed-vnf
61 - member-vnf-index-ref: '2'
62 vnfd-connection-point-ref: vnf-mgmt
63 vnfd-id-ref: hackfest3charmed-vnf
64 - id: datanet
65 name: datanet
66 short-name: datanet
67 type: ELAN
68 vnfd-connection-point-ref:
69 - member-vnf-index-ref: '1'
70 vnfd-connection-point-ref: vnf-data
71 vnfd-id-ref: hackfest3charmed-vnf
72 - member-vnf-index-ref: '2'
73 vnfd-connection-point-ref: vnf-data
74 vnfd-id-ref: hackfest3charmed-vnf
75 - _admin:
76 created: 1575031728.9257665
77 modified: 1575031728.9257665
78 onboardingState: ONBOARDED
79 operationalState: ENABLED
80 projects_read:
81 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
82 projects_write:
83 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
84 storage:
85 descriptor: multikdu_ns/multikdu_nsd.yaml
86 folder: d0f63683-9032-4c6f-8928-ffd4674b9f69
87 fs: local
88 path: /app/storage/
89 pkg-dir: multikdu_ns
90 zipfile: multikdu_ns.tar.gz
91 usageState: NOT_IN_USE
92 userDefinedData: {}
93 _id: d0f63683-9032-4c6f-8928-ffd4674b9f69
94 constituent-vnfd:
95 - member-vnf-index: multikdu
96 vnfd-id-ref: multikdu_knf
97 description: NS consisting of a single KNF multikdu_knf connected to mgmt network
98 id: multikdu_ns
99 logo: osm.png
100 name: multikdu_ns
101 short-name: multikdu_ns
102 vendor: OSM
103 version: '1.0'
104 vld:
105 - id: mgmtnet
106 mgmt-network: true
107 name: mgmtnet
108 type: ELAN
109 vim-network-name: mgmt
110 vnfd-connection-point-ref:
111 - member-vnf-index-ref: multikdu
112 vnfd-connection-point-ref: mgmt
113 vnfd-id-ref: multikdu_knf
114 """
115
116 db_nslcmops_text = """
117 ---
118 - _admin:
119 created: 1566823354.4148262
120 modified: 1566823354.4148262
121 projects_read:
122 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
123 projects_write:
124 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
125 worker: 86434c2948e2
126 operations:
127 - member_vnf_index: '1'
128 primitive: touch
129 primitive_params: /home/ubuntu/last-touch-1
130 operationState: COMPLETED
131 detailed-status: Done
132 - member_vnf_index: '1'
133 primitive: touch
134 primitive_params: /home/ubuntu/last-touch-2
135 operationState: COMPLETED
136 detailed-status: Done
137 - member_vnf_index: '2'
138 primitive: touch
139 primitive_params: /home/ubuntu/last-touch-3
140 operationState: FAILED
141 detailed-status: Unknown error
142 _id: a639fac7-e0bb-4225-8ecb-c1f8efcc125e
143 detailed-status: 'FAILED executing proxy charm initial primitives for member_vnf_index=1
144 vdu_id=None: charm error executing primitive verify-ssh-credentials for member_vnf_index=1
145 vdu_id=None: ''timeout after 600 seconds'''
146 id: a639fac7-e0bb-4225-8ecb-c1f8efcc125e
147 isAutomaticInvocation: false
148 isCancelPending: false
149 lcmOperationType: instantiate
150 links:
151 nsInstance: /osm/nslcm/v1/ns_instances/f48163a6-c807-47bc-9682-f72caef5af85
152 self: /osm/nslcm/v1/ns_lcm_op_occs/a639fac7-e0bb-4225-8ecb-c1f8efcc125e
153 nsInstanceId: f48163a6-c807-47bc-9682-f72caef5af85
154 operationParams:
155 additionalParamsForVnf:
156 - additionalParams:
157 touch_filename: /home/ubuntu/first-touch-1
158 touch_filename2: /home/ubuntu/second-touch-1
159 member-vnf-index: '1'
160 - additionalParams:
161 touch_filename: /home/ubuntu/first-touch-2
162 touch_filename2: /home/ubuntu/second-touch-2
163 member-vnf-index: '2'
164 lcmOperationType: instantiate
165 nsDescription: default description
166 nsInstanceId: f48163a6-c807-47bc-9682-f72caef5af85
167 nsName: ALF
168 nsdId: 8c2f8b95-bb1b-47ee-8001-36dc090678da
169 vimAccountId: ea958ba5-4e58-4405-bf42-6e3be15d4c3a
170 operationState: FAILED
171 startTime: 1566823354.414689
172 statusEnteredTime: 1566824534.5112448
173
174 - _admin:
175 created: 1600000000.0000000
176 modified: 1600000000.0000000
177 projects_read:
178 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
179 projects_write:
180 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
181 worker: 86434c2948e2
182 _id: a639fac7-e0bb-4225-ffff-c1f8efcc125e
183 detailed-status: None
184 lcmOperationType: terminate
185 nsInstanceId: f48163a6-c807-47bc-9682-f72caef5af85
186 operationParams: {}
187 operationState: PROCESSING
188 startTime: 1600000000.0000000
189 statusEnteredTime: 1600000000.0000000
190
191 - _admin:
192 created: 1575034637.044651
193 modified: 1575034637.044651
194 projects_read:
195 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
196 projects_write:
197 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
198 _id: cf3aa178-7640-4174-b921-2330e6f2aad6
199 detailed-status: done
200 id: cf3aa178-7640-4174-b921-2330e6f2aad6
201 isAutomaticInvocation: false
202 isCancelPending: false
203 lcmOperationType: instantiate
204 links:
205 nsInstance: /osm/nslcm/v1/ns_instances/0bcb701c-ee4d-41ab-8ee6-f4156f7f114d
206 self: /osm/nslcm/v1/ns_lcm_op_occs/cf3aa178-7640-4174-b921-2330e6f2aad6
207 nsInstanceId: 0bcb701c-ee4d-41ab-8ee6-f4156f7f114d
208 operationParams:
209 lcmOperationType: instantiate
210 nsDescription: default description
211 nsInstanceId: 0bcb701c-ee4d-41ab-8ee6-f4156f7f114d
212 nsName: multikdu
213 nsdId: d0f63683-9032-4c6f-8928-ffd4674b9f69
214 nsr_id: 0bcb701c-ee4d-41ab-8ee6-f4156f7f114d
215 vimAccountId: 74337dcb-ef54-41e7-bd2d-8c0d7fcd326f
216 vld:
217 - name: mgmtnet
218 vim-network-name: internal
219 operationState: COMPLETED
220 startTime: 1575034637.0445576
221 statusEnteredTime: 1575034663.8484545
222 """
223
224 db_nsrs_text = """
225 ---
226 - _admin:
227 created: 1566823354.3716335
228 deployed:
229 RO:
230 nsd_id: 876573b5-968d-40b9-b52b-91bf5c5844f7
231 nsr_id: c9fe9908-3180-430d-b633-fca2f68db008
232 nsr_status: ACTIVE
233 vnfd:
234 - id: 1ab2a418-9fe3-4358-bf17-411e5155535f
235 member-vnf-index: '1'
236 - id: 0de348e3-c201-4f6a-91cc-7f957e2d5504
237 member-vnf-index: '2'
238 VCA:
239 - application: alf-b-aa
240 ee_id: f48163a6-c807-47bc-9682-f72caef5af85.alf-b-aa
241 needed_terminate: True
242 detailed-status: Ready!
243 member-vnf-index: '1'
244 model: f48163a6-c807-47bc-9682-f72caef5af85
245 operational-status: active
246 primitive_id: null
247 ssh-public-key: ssh-rsa pub-key root@juju-145d3e-0
248 step: ssh-public-key-obtained
249 vdu_count_index: null
250 vdu_id: null
251 vdu_name: null
252 vnfd_id: hackfest3charmed-vnf
253 - application: alf-c-ab
254 ee_id: f48163a6-c807-47bc-9682-f72caef5af85.alf-c-ab
255 needed_terminate: True
256 detailed-status: Ready!
257 member-vnf-index: '2'
258 model: f48163a6-c807-47bc-9682-f72caef5af85
259 operational-status: active
260 primitive_id: null
261 ssh-public-key: ssh-rsa pub-key root@juju-145d3e-0
262 step: ssh-public-key-obtained
263 vdu_count_index: null
264 vdu_id: null
265 vdu_name: null
266 vnfd_id: hackfest3charmed-vnf
267 VCA-model-name: f48163a6-c807-47bc-9682-f72caef5af85
268 modified: 1566823354.3716335
269 nsState: INSTANTIATED
270 nslcmop: null
271 projects_read:
272 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
273 projects_write:
274 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
275 _id: f48163a6-c807-47bc-9682-f72caef5af85
276 additionalParamsForNs: null
277 admin-status: ENABLED
278 config-status: init
279 constituent-vnfr-ref:
280 - 88d90b0c-faff-4b9f-bccd-017f33985984
281 - 1ca3bb1a-b29b-49fe-bed6-5f3076d77434
282 create-time: 1566823354.36234
283 datacenter: ea958ba5-4e58-4405-bf42-6e3be15d4c3a
284 description: default description
285 detailed-status: 'ERROR executing proxy charm initial primitives for member_vnf_index=1
286 vdu_id=None: charm error executing primitive verify-ssh-credentials for member_vnf_index=1
287 vdu_id=None: ''timeout after 600 seconds'''
288 id: f48163a6-c807-47bc-9682-f72caef5af85
289 instantiate_params:
290 nsDescription: default description
291 nsName: ALF
292 nsdId: 8c2f8b95-bb1b-47ee-8001-36dc090678da
293 vimAccountId: ea958ba5-4e58-4405-bf42-6e3be15d4c3a
294 name: ALF
295 name-ref: ALF
296 ns-instance-config-ref: f48163a6-c807-47bc-9682-f72caef5af85
297 nsd:
298 _admin:
299 created: 1566823353.971486
300 modified: 1566823353.971486
301 onboardingState: ONBOARDED
302 operationalState: ENABLED
303 projects_read:
304 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
305 projects_write:
306 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
307 storage:
308 descriptor: hackfest_3charmed_nsd/hackfest_3charmed_nsd.yaml
309 folder: 8c2f8b95-bb1b-47ee-8001-36dc090678da
310 fs: local
311 path: /app/storage/
312 pkg-dir: hackfest_3charmed_nsd
313 zipfile: package.tar.gz
314 usageState: NOT_IN_USE
315 userDefinedData: {}
316 _id: 8c2f8b95-bb1b-47ee-8001-36dc090678da
317 constituent-vnfd:
318 - member-vnf-index: '1'
319 vnfd-id-ref: hackfest3charmed-vnf
320 - member-vnf-index: '2'
321 vnfd-id-ref: hackfest3charmed-vnf
322 description: NS with 2 VNFs hackfest3charmed-vnf connected by datanet and
323 mgmtnet VLs
324 id: hackfest3charmed-ns
325 logo: osm.png
326 name: hackfest3charmed-ns
327 short-name: hackfest3charmed-ns
328 version: '1.0'
329 vld:
330 - id: mgmt
331 mgmt-network: true
332 name: mgmt
333 short-name: mgmt
334 type: ELAN
335 vim-network-name: mgmt
336 vnfd-connection-point-ref:
337 - member-vnf-index-ref: '1'
338 vnfd-connection-point-ref: vnf-mgmt
339 vnfd-id-ref: hackfest3charmed-vnf
340 - member-vnf-index-ref: '2'
341 vnfd-connection-point-ref: vnf-mgmt
342 vnfd-id-ref: hackfest3charmed-vnf
343 - id: datanet
344 name: datanet
345 short-name: datanet
346 type: ELAN
347 vnfd-connection-point-ref:
348 - member-vnf-index-ref: '1'
349 vnfd-connection-point-ref: vnf-data
350 vnfd-id-ref: hackfest3charmed-vnf
351 - member-vnf-index-ref: '2'
352 vnfd-connection-point-ref: vnf-data
353 vnfd-id-ref: hackfest3charmed-vnf
354 nsd-id: 8c2f8b95-bb1b-47ee-8001-36dc090678da
355 nsd-name-ref: hackfest3charmed-ns
356 nsd-ref: hackfest3charmed-ns
357 operational-events: []
358 operational-status: failed
359 orchestration-progress: {}
360 resource-orchestrator: osmopenmano
361 short-name: ALF
362 ssh-authorized-key: null
363 vld:
364 - id: mgmt
365 name: null
366 status: ACTIVE
367 status-detailed: null
368 vim-id: f99ae780-0e2f-4985-af41-574eae6919c0
369 vim-network-name: mgmt
370 - id: datanet
371 name: ALF-datanet
372 status: ACTIVE
373 status-detailed: null
374 vim-id: c31364ba-f573-4ab6-bf1a-fed30ede39a8
375 vnfd-id:
376 - 7637bcf8-cf14-42dc-ad70-c66fcf1e6e77
377 - _admin:
378 created: 1575034637.011233
379 current-operation: null
380 deployed:
381 K8s:
382 - k8scluster-uuid: 73d96432-d692-40d2-8440-e0c73aee209c
383 kdu-instance: stable-mongodb-0086856106
384 kdu-model: stable/mongodb
385 kdu-name: mongo
386 vnfr-id: 5ac34899-a23a-4b3c-918a-cd77acadbea6
387 - k8scluster-uuid: 73d96432-d692-40d2-8440-e0c73aee209c
388 kdu-instance: stable-openldap-0092830263
389 kdu-model: stable/mongodb
390 kdu-name: mongo
391 vnfr-id: 5ac34899-a23a-4b3c-918a-cd77acadbea6
392 RO:
393 detailed-status: Deployed at VIM
394 nsd_id: b03a8de8-1898-4142-bc6d-3b0787df567d
395 nsr_id: b5ce3e00-8647-415d-afaa-d5a612cf3074
396 nsr_status: ACTIVE
397 operational-status: running
398 vnfd:
399 - id: b9493dae-a4c9-4b96-8965-329581efb0a1
400 member-vnf-index: multikdu
401 VCA: []
402 modified: 1575034637.011233
403 nsState: INSTANTIATED
404 nslcmop: null
405 operation-type: null
406 projects_read:
407 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
408 projects_write:
409 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
410 _id: 0bcb701c-ee4d-41ab-8ee6-f4156f7f114d
411 additionalParamsForNs: null
412 admin-status: ENABLED
413 config-status: configured
414 constituent-vnfr-ref:
415 - 5ac34899-a23a-4b3c-918a-cd77acadbea6
416 create-time: 1575034636.9990137
417 datacenter: ea958ba5-4e58-4405-bf42-6e3be15d4c3a
418 description: default description
419 detailed-status: done
420 id: 0bcb701c-ee4d-41ab-8ee6-f4156f7f114d
421 instantiate_params:
422 nsDescription: default description
423 nsName: multikdu
424 nsdId: d0f63683-9032-4c6f-8928-ffd4674b9f69
425 vimAccountId: 74337dcb-ef54-41e7-bd2d-8c0d7fcd326f
426 name: multikdu
427 name-ref: multikdu
428 ns-instance-config-ref: 0bcb701c-ee4d-41ab-8ee6-f4156f7f114d
429 nsd-id: d0f63683-9032-4c6f-8928-ffd4674b9f69
430 nsd-name-ref: multikdu_ns
431 nsd-ref: multikdu_ns
432 operational-events: []
433 operational-status: init
434 orchestration-progress: {}
435 resource-orchestrator: osmopenmano
436 short-name: multikdu
437 ssh-authorized-key: null
438 vld:
439 - id: mgmtnet
440 name: null
441 status: ACTIVE
442 status-detailed: null
443 vim-id: 9b6a2ac4-767e-4ec9-9497-8ba63084c77f
444 vim-network-name: mgmt
445 vnfd-id:
446 - 7ab0d10d-8ce2-4c68-aef6-cc5a437a9c62
447 """
448
449 ro_ns_text = """
450 datacenter_tenant_id: dc5c67fa-c7f2-11e9-b9c0-02420aff0004
451 description: null
452 name: ALF
453 classifications: []
454 sdn_nets: []
455 nets:
456 - created: false
457 datacenter_id: dc51ce6c-c7f2-11e9-b9c0-02420aff0004
458 datacenter_tenant_id: dc5c67fa-c7f2-11e9-b9c0-02420aff0004
459 error_msg: null
460 ns_net_osm_id: mgmt
461 related: c6bac394-fa27-4c43-bb34-42f621a9d343
462 sce_net_id: 8f215bab-c35e-41e6-a035-42bfaa07af9f
463 sdn_net_id: null
464 status: ACTIVE
465 uuid: c6bac394-fa27-4c43-bb34-42f621a9d343
466 vim_info: "{vim_info: null}"
467 vim_name: null
468 vim_net_id: f99ae780-0e2f-4985-af41-574eae6919c0
469 vnf_net_id: null
470 vnf_net_osm_id: null
471 - created: true
472 datacenter_id: dc51ce6c-c7f2-11e9-b9c0-02420aff0004
473 datacenter_tenant_id: dc5c67fa-c7f2-11e9-b9c0-02420aff0004
474 error_msg: null
475 ns_net_osm_id: datanet
476 related: 509d576c-120f-493a-99a1-5fea99dfe041
477 sce_net_id: 3d766bbc-33a8-41aa-a986-2f35e8d25c16
478 sdn_net_id: null
479 status: ACTIVE
480 uuid: 509d576c-120f-493a-99a1-5fea99dfe041
481 vim_info: "{vim_info: null}"
482 vim_name: ALF-datanet
483 vim_net_id: c31364ba-f573-4ab6-bf1a-fed30ede39a8
484 vnf_net_id: null
485 vnf_net_osm_id: null
486 - created: true
487 datacenter_id: dc51ce6c-c7f2-11e9-b9c0-02420aff0004
488 datacenter_tenant_id: dc5c67fa-c7f2-11e9-b9c0-02420aff0004
489 error_msg: null
490 ns_net_osm_id: null
491 related: 277fed09-3220-4bfd-9052-b96b21a32daf
492 sce_net_id: null
493 sdn_net_id: null
494 status: ACTIVE
495 uuid: 277fed09-3220-4bfd-9052-b96b21a32daf
496 vim_info: "{vim_info: null}"
497 vim_name: ALF-internal
498 vim_net_id: ff181e6d-2597-4244-b40b-bb0174bdfeb6
499 vnf_net_id: 62e62fae-c12b-4ebc-9a9b-30031c6c16fa
500 vnf_net_osm_id: internal
501 - created: true
502 datacenter_id: dc51ce6c-c7f2-11e9-b9c0-02420aff0004
503 datacenter_tenant_id: dc5c67fa-c7f2-11e9-b9c0-02420aff0004
504 error_msg: null
505 ns_net_osm_id: null
506 related: 92534d1a-e697-4372-a84d-aa0aa643b68a
507 sce_net_id: null
508 sdn_net_id: null
509 status: ACTIVE
510 uuid: 92534d1a-e697-4372-a84d-aa0aa643b68a
511 vim_info: "{vim_info: null}"
512 vim_name: ALF-internal
513 vim_net_id: 09655387-b639-421a-b5f6-72b26d685fb4
514 vnf_net_id: 13c6c77d-86a5-4914-832c-990d4ec7b54e
515 vnf_net_osm_id: internal
516 nsd_osm_id: f48163a6-c807-47bc-9682-f72caef5af85.2.hackfest3charmed-ns
517 scenario_id: 876573b5-968d-40b9-b52b-91bf5c5844f7
518 scenario_name: hackfest3charmed-ns
519 sfis: []
520 sfps: []
521 sfs: []
522 tenant_id: 0ea38bd0-2729-47a9-ae07-c6ce76115eb2
523 uuid: c9fe9908-3180-430d-b633-fca2f68db008
524 vnfs:
525 - datacenter_id: dc51ce6c-c7f2-11e9-b9c0-02420aff0004
526 datacenter_tenant_id: dc5c67fa-c7f2-11e9-b9c0-02420aff0004
527 ip_address: 10.205.1.46
528 member_vnf_index: '1'
529 mgmt_access: '{interface_id: 61549ee3-cd6c-4930-8b90-eaad97fe345b, required: ''False'',
530 vm_id: 6cf4a48f-3b6c-4395-8221-119fa37de24a}
531
532 '
533 sce_vnf_id: 83be04a8-c513-42ba-9908-22728f686d31
534 uuid: 94724042-7576-4fb0-82ec-6a7ab642741c
535 vms:
536 - created_at: '2019-08-26T12:50:38'
537 error_msg: null
538 interfaces:
539 - external_name: vnf-mgmt
540 instance_net_id: c6bac394-fa27-4c43-bb34-42f621a9d343
541 internal_name: mgmtVM-eth0
542 ip_address: 10.205.1.46
543 mac_address: fa:16:3e:b4:3e:b1
544 sdn_port_id: null
545 type: mgmt
546 vim_info: "{vim_info: null}"
547 vim_interface_id: 4d3cb8fd-7040-4169-a0ad-2486d2b006a1
548 - external_name: null
549 instance_net_id: 277fed09-3220-4bfd-9052-b96b21a32daf
550 internal_name: mgmtVM-eth1
551 ip_address: 192.168.54.2
552 mac_address: fa:16:3e:6e:7e:78
553 sdn_port_id: null
554 type: bridge
555 vim_info: "{vim_info: null}"
556 vim_interface_id: 54ed68e2-9802-4dfe-b68a-280b3fc6e02d
557 ip_address: 10.205.1.46
558 name: mgmtVM
559 related: d0b91293-a91d-4f08-b15f-0bf841216dfe
560 status: ACTIVE
561 uuid: d0b91293-a91d-4f08-b15f-0bf841216dfe
562 vdu_osm_id: mgmtVM
563 vim_info: "{vim_info: null}"
564 vim_name: ALF-1-mgmtVM-1
565 vim_vm_id: c2538499-4c30-41c0-acd5-80cb92f48061
566 - created_at: '2019-08-26T12:50:38'
567 error_msg: null
568 interfaces:
569 - external_name: null
570 instance_net_id: 277fed09-3220-4bfd-9052-b96b21a32daf
571 internal_name: dataVM-eth0
572 ip_address: 192.168.54.3
573 mac_address: fa:16:3e:d9:7a:5d
574 sdn_port_id: null
575 type: bridge
576 vim_info: "{vim_info: null}"
577 vim_interface_id: 1637f350-8840-4241-8ed0-4616bdcecfcf
578 - external_name: vnf-data
579 instance_net_id: 509d576c-120f-493a-99a1-5fea99dfe041
580 internal_name: dataVM-xe0
581 ip_address: 192.168.24.3
582 mac_address: fa:16:3e:d1:6c:0d
583 sdn_port_id: null
584 type: bridge
585 vim_info: "{vim_info: null}"
586 vim_interface_id: 54c73e83-7059-41fe-83a9-4c4ae997b481
587 name: dataVM
588 related: 5c08253d-8a35-474f-b0d3-c5297d174c13
589 status: ACTIVE
590 uuid: 5c08253d-8a35-474f-b0d3-c5297d174c13
591 vdu_osm_id: dataVM
592 vim_info: "{vim_info: null}"
593 vim_name: ALF-1-dataVM-1
594 vim_vm_id: 87973c3f-365d-4227-95c2-7a8abc74349c
595 - created_at: '2019-08-26T13:40:54'
596 error_msg: null
597 interfaces:
598 - external_name: null
599 instance_net_id: 277fed09-3220-4bfd-9052-b96b21a32daf
600 internal_name: dataVM-eth0
601 ip_address: 192.168.54.5
602 mac_address: fa:16:3e:e4:17:45
603 sdn_port_id: null
604 type: bridge
605 vim_info: "{vim_info: null}"
606 vim_interface_id: 7e246e40-8710-4c33-9c95-78fc3c02bc5b
607 - external_name: vnf-data
608 instance_net_id: 509d576c-120f-493a-99a1-5fea99dfe041
609 internal_name: dataVM-xe0
610 ip_address: 192.168.24.5
611 mac_address: fa:16:3e:29:6f:a6
612 sdn_port_id: null
613 type: bridge
614 vim_info: "{vim_info: null}"
615 vim_interface_id: ce81af7a-9adf-494b-950e-6581fd04ecc4
616 name: dataVM
617 related: 1ae5a0a2-c15a-49a4-a77c-2991d97f6dbe
618 status: ACTIVE
619 uuid: 1ae5a0a2-c15a-49a4-a77c-2991d97f6dbe
620 vdu_osm_id: dataVM
621 vim_info: "{vim_info: null}"
622 vim_name: ALF-1-dataVM-2
623 vim_vm_id: 4916533e-36c6-4861-9fe3-366a8fb0a5f8
624 vnf_id: 1ab2a418-9fe3-4358-bf17-411e5155535f
625 vnf_name: hackfest3charmed-vnf.1
626 vnfd_osm_id: f48163a6-c807-47bc-9682-f72caef5af85.0.1
627 - datacenter_id: dc51ce6c-c7f2-11e9-b9c0-02420aff0004
628 datacenter_tenant_id: dc5c67fa-c7f2-11e9-b9c0-02420aff0004
629 ip_address: 10.205.1.47
630 member_vnf_index: '2'
631 mgmt_access: '{interface_id: 538604c3-5c5e-41eb-8f84-c0239c7fabcd, required: ''False'',
632 vm_id: dd04d792-05c9-4ecc-bf28-f77384d00311}
633
634 '
635 sce_vnf_id: c4f3607a-08ff-4f75-893c-fce507e2f240
636 uuid: 00020403-e80f-4ef2-bb7e-b29669643035
637 vms:
638 - created_at: '2019-08-26T12:50:38'
639 error_msg: null
640 interfaces:
641 - external_name: vnf-mgmt
642 instance_net_id: c6bac394-fa27-4c43-bb34-42f621a9d343
643 internal_name: mgmtVM-eth0
644 ip_address: 10.205.1.47
645 mac_address: fa:16:3e:cb:9f:c7
646 sdn_port_id: null
647 type: mgmt
648 vim_info: "{vim_info: null}"
649 vim_interface_id: dcd6d2de-3c68-481c-883e-e9d38c671dc4
650 - external_name: null
651 instance_net_id: 92534d1a-e697-4372-a84d-aa0aa643b68a
652 internal_name: mgmtVM-eth1
653 ip_address: 192.168.231.1
654 mac_address: fa:16:3e:1a:89:24
655 sdn_port_id: null
656 type: bridge
657 vim_info: "{vim_info: null}"
658 vim_interface_id: 50e538e3-aba0-4652-93bb-20487f3f28e1
659 ip_address: 10.205.1.47
660 name: mgmtVM
661 related: 4543ab5d-578c-427c-9df2-affd17e21b66
662 status: ACTIVE
663 uuid: 4543ab5d-578c-427c-9df2-affd17e21b66
664 vdu_osm_id: mgmtVM
665 vim_info: "{vim_info: null}"
666 vim_name: ALF-2-mgmtVM-1
667 vim_vm_id: 248077b2-e3b8-4a37-8b72-575abb8ed912
668 - created_at: '2019-08-26T12:50:38'
669 error_msg: null
670 interfaces:
671 - external_name: null
672 instance_net_id: 92534d1a-e697-4372-a84d-aa0aa643b68a
673 internal_name: dataVM-eth0
674 ip_address: 192.168.231.3
675 mac_address: fa:16:3e:7e:ba:8c
676 sdn_port_id: null
677 type: bridge
678 vim_info: "{vim_info: null}"
679 vim_interface_id: 15274862-14ea-4527-b405-101cae8bc1a0
680 - external_name: vnf-data
681 instance_net_id: 509d576c-120f-493a-99a1-5fea99dfe041
682 internal_name: dataVM-xe0
683 ip_address: 192.168.24.4
684 mac_address: fa:16:3e:d2:e1:f5
685 sdn_port_id: null
686 type: bridge
687 vim_info: "{vim_info: null}"
688 vim_interface_id: 253ebe4e-38d5-46be-8777-dbb57510a2ec
689 name: dataVM
690 related: 6f03f16b-295a-47a1-9a69-2d069d574a33
691 status: ACTIVE
692 uuid: 6f03f16b-295a-47a1-9a69-2d069d574a33
693 vdu_osm_id: dataVM
694 vim_info: "{vim_info: null}"
695 vim_name: ALF-2-dataVM-1
696 vim_vm_id: a4ce4372-e0ad-4ae3-8f9f-1c969f32e77b
697 vnf_id: 0de348e3-c201-4f6a-91cc-7f957e2d5504
698 vnf_name: hackfest3charmed-vnf.2
699 vnfd_osm_id: f48163a6-c807-47bc-9682-f72caef5af85.1.2
700 """
701
702 ro_delete_action_text = """
703 actions:
704 - created_at: 1580140763.1099188
705 description: DELETE
706 instance_id: c9fe9908-3180-430d-b633-fca2f68db008
707 modified_at: 1580140763.253148
708 number_done: 1
709 number_failed: 0
710 number_tasks: 1
711 tenant_id: 0ea38bd0-2729-47a9-ae07-c6ce76115eb2
712 uuid: delete
713 vim_wim_actions:
714 - action: DELETE
715 created_at: 1580140763.1099188
716 datacenter_vim_id: dc5c67fa-c7f2-11e9-b9c0-02420aff0004
717 error_msg: null
718 extra: '{params: [9b6a2ac4-767e-4ec9-9497-8ba63084c77f, null]}'
719 instance_action_id: ACTION-1580140763.054037
720 item: instance_nets
721 item_id: 8cb06b72-c71d-4b58-b419-95025fa651d3
722 modified_at: 1580140763.1099188
723 related: 8cb06b72-c71d-4b58-b419-95025fa651d3
724 status: SUPERSEDED
725 task_index: 0
726 vim_id: null
727 wim_account_id: null
728 wim_internal_id: null
729 worker: null
730 """
731
732 db_vim_accounts_text = """
733 ---
734 - _admin:
735 created: 1566818150.3024442
736 current_operation: 0
737 deployed:
738 RO: dc51ce6c-c7f2-11e9-b9c0-02420aff0004
739 RO-account: dc5c67fa-c7f2-11e9-b9c0-02420aff0004
740 detailed-status: Done
741 modified: 1566818150.3024442
742 operationalState: ENABLED
743 operations:
744 - detailed-status: Done
745 lcmOperationType: create
746 operationParams: null
747 operationState: COMPLETED
748 startTime: 1566818150.3025382
749 statusEnteredTime: 1566818150.3025382
750 worker: 86434c2948e2
751 projects_read:
752 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
753 projects_write:
754 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
755 _id: ea958ba5-4e58-4405-bf42-6e3be15d4c3a
756 description: some description here
757 name: vim1
758 schema_version: '1.1'
759 vim_password: 5g0yGX86qIhprX86YTMcpg==
760 vim_tenant_name: osm
761 vim_type: openstack
762 vim_url: http://10.95.87.162:5000/v2.0
763 vim_user: osm
764 - _admin:
765 created: 1566818150.3024442
766 current_operation: 0
767 deployed:
768 RO: 9ac17c0d-4265-4333-843b-c3cbd1f93f88
769 RO-account: 011895dc-ab34-4c9f-b06f-401a8ffb073b
770 detailed-status: Done
771 modified: 1566818150.3024442
772 operationalState: ENABLED
773 operations:
774 - detailed-status: Done
775 lcmOperationType: create
776 operationParams: null
777 operationState: COMPLETED
778 startTime: 1566818150.3025382
779 statusEnteredTime: 1566818150.3025382
780 worker: 86434c2948e2
781 projects_read:
782 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
783 projects_write:
784 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
785 _id: 05357241-1a01-416f-9e02-af20f65f51cd
786 description: No description
787 name: vim2
788 schema_version: '1.1'
789 vim_password: 5g0yGX86qIhprX86YTMcpg==
790 vim_tenant_name: osm
791 vim_type: dumy
792 vim_url: http://10.95.88.162:5000/v2.0
793 vim_user: osm
794 """
795
796 db_k8sclusters_text = """
797 - _admin:
798 created: 1575031378.9268339
799 current_operation: 0
800 modified: 1575031378.9268339
801 operationalState: ENABLED
802 operations:
803 - detailed-status: ''
804 lcmOperationType: create
805 operationParams: null
806 operationState: ''
807 startTime: 1575031378.926895
808 statusEnteredTime: 1575031378.926895
809 worker: 36681ccf7f32
810 projects_read:
811 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
812 projects_write:
813 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
814 helm-chart:
815 id: 73d96432-d692-40d2-8440-e0c73aee209c
816 created: True
817 helm-chart-v3:
818 id: 73d96432-d692-40d2-8440-e0c73aee209c
819 created: True
820 _id: e7169dab-f71a-4f1f-b82b-432605e8c4b3
821 credentials:
822 apiVersion: v1
823 users:
824 - name: admin
825 user:
826 password: qhpdogJXhBLG+JiYyyE0LeNsJXHkCSMy+sGVzlnJqes=
827 username: admin
828 description: Cluster3
829 k8s_version: '1.15'
830 name: cluster3
831 namespace: kube-system
832 nets:
833 net1: None
834 schema_version: '1.11'
835 vim_account: ea958ba5-4e58-4405-bf42-6e3be15d4c3a
836 """
837
838 db_vnfds_text = """
839 ---
840 - _admin:
841 created: 1566823352.7154346
842 modified: 1566823353.9295402
843 onboardingState: ONBOARDED
844 operationalState: ENABLED
845 projects_read:
846 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
847 projects_write:
848 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
849 storage:
850 descriptor: hackfest_3charmed_vnfd/hackfest_3charmed_vnfd.yaml
851 folder: 7637bcf8-cf14-42dc-ad70-c66fcf1e6e77
852 fs: local
853 path: /app/storage/
854 pkg-dir: hackfest_3charmed_vnfd
855 zipfile: package.tar.gz
856 type: vnfd
857 usageState: NOT_IN_USE
858 userDefinedData: {}
859 _id: 7637bcf8-cf14-42dc-ad70-c66fcf1e6e77
860 connection-point:
861 - id: vnf-mgmt
862 name: vnf-mgmt
863 short-name: vnf-mgmt
864 type: VPORT
865 - id: vnf-data
866 name: vnf-data
867 short-name: vnf-data
868 type: VPORT
869 description: A VNF consisting of 2 VDUs connected to an internal VL, and one VDU
870 with cloud-init
871 id: hackfest3charmed-vnf
872 internal-vld:
873 - id: internal
874 internal-connection-point:
875 - id-ref: mgmtVM-internal
876 - id-ref: dataVM-internal
877 name: internal
878 short-name: internal
879 type: ELAN
880 logo: osm.png
881 mgmt-interface:
882 cp: vnf-mgmt
883 monitoring-param:
884 - aggregation-type: AVERAGE
885 id: monitor1
886 name: monitor1
887 vdu-monitoring-param:
888 vdu-monitoring-param-ref: dataVM_cpu_util
889 vdu-ref: dataVM
890 name: hackfest3charmed-vnf
891 scaling-group-descriptor:
892 - max-instance-count: 10
893 name: scale_dataVM
894 scaling-config-action:
895 - trigger: post-scale-out
896 vnf-config-primitive-name-ref: touch
897 - trigger: pre-scale-in
898 vnf-config-primitive-name-ref: touch
899 scaling-policy:
900 - cooldown-time: 60
901 name: auto_cpu_util_above_threshold
902 scaling-criteria:
903 - name: cpu_util_above_threshold
904 scale-in-relational-operation: LE
905 scale-in-threshold: '15.0000000000'
906 scale-out-relational-operation: GE
907 scale-out-threshold: '60.0000000000'
908 vnf-monitoring-param-ref: monitor1
909 scaling-type: automatic
910 threshold-time: 0
911 vdu:
912 - count: 1
913 vdu-id-ref: dataVM
914 short-name: hackfest3charmed-vnf
915 vdu:
916 - count: '1'
917 cloud-init-file: cloud-config.txt
918 id: mgmtVM
919 image: hackfest3-mgmt
920 interface:
921 - external-connection-point-ref: vnf-mgmt
922 name: mgmtVM-eth0
923 position: 1
924 type: EXTERNAL
925 virtual-interface:
926 type: VIRTIO
927 - internal-connection-point-ref: mgmtVM-internal
928 name: mgmtVM-eth1
929 position: 2
930 type: INTERNAL
931 virtual-interface:
932 type: VIRTIO
933 internal-connection-point:
934 - id: mgmtVM-internal
935 name: mgmtVM-internal
936 short-name: mgmtVM-internal
937 type: VPORT
938 name: mgmtVM
939 vm-flavor:
940 memory-mb: '1024'
941 storage-gb: '10'
942 vcpu-count: 1
943 - count: '1'
944 id: dataVM
945 image: hackfest3-mgmt
946 interface:
947 - internal-connection-point-ref: dataVM-internal
948 name: dataVM-eth0
949 position: 1
950 type: INTERNAL
951 virtual-interface:
952 type: VIRTIO
953 - external-connection-point-ref: vnf-data
954 name: dataVM-xe0
955 position: 2
956 type: EXTERNAL
957 virtual-interface:
958 type: VIRTIO
959 internal-connection-point:
960 - id: dataVM-internal
961 name: dataVM-internal
962 short-name: dataVM-internal
963 type: VPORT
964 monitoring-param:
965 - id: dataVM_cpu_util
966 nfvi-metric: cpu_utilization
967 name: dataVM
968 vm-flavor:
969 memory-mb: '1024'
970 storage-gb: '10'
971 vcpu-count: 1
972 version: '1.0'
973 vnf-configuration:
974 config-access:
975 ssh-access:
976 required: True
977 default-user: ubuntu
978 config-primitive:
979 - name: touch
980 parameter:
981 - data-type: STRING
982 default-value: <touch_filename2>
983 name: filename
984 initial-config-primitive:
985 - name: config
986 parameter:
987 - name: ssh-hostname
988 value: <rw_mgmt_ip>
989 - name: ssh-username
990 value: ubuntu
991 - name: ssh-password
992 value: osm4u
993 seq: '1'
994 - name: touch
995 parameter:
996 - name: filename
997 value: <touch_filename>
998 seq: '2'
999 juju:
1000 charm: simple
1001 - _admin:
1002 created: 1575031727.5383403
1003 modified: 1575031727.5383403
1004 onboardingState: ONBOARDED
1005 operationalState: ENABLED
1006 projects_read:
1007 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
1008 projects_write:
1009 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
1010 storage:
1011 descriptor: multikdu_knf/multikdu_vnfd.yaml
1012 folder: 7ab0d10d-8ce2-4c68-aef6-cc5a437a9c62
1013 fs: local
1014 path: /app/storage/
1015 pkg-dir: multikdu_knf
1016 zipfile: multikdu_knf.tar.gz
1017 usageState: NOT_IN_USE
1018 userDefinedData: {}
1019 _id: 7ab0d10d-8ce2-4c68-aef6-cc5a437a9c62
1020 connection-point:
1021 - name: mgmt
1022 description: KNF with two KDU using helm-charts
1023 id: multikdu_knf
1024 k8s-cluster:
1025 nets:
1026 - external-connection-point-ref: mgmt
1027 id: mgmtnet
1028 kdu:
1029 - helm-chart: stable/openldap:1.2.1
1030 name: ldap
1031 - helm-chart: stable/mongodb
1032 name: mongo
1033 mgmt-interface:
1034 cp: mgmt
1035 name: multikdu_knf
1036 short-name: multikdu_knf
1037 vendor: Telefonica
1038 version: '1.0'
1039 """
1040
1041 db_vnfrs_text = """
1042 ---
1043 - _admin:
1044 created: 1566823354.3668208
1045 modified: 1566823354.3668208
1046 nsState: NOT_INSTANTIATED
1047 projects_read:
1048 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
1049 projects_write:
1050 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
1051 _id: 88d90b0c-faff-4b9f-bccd-017f33985984
1052 additionalParamsForVnf:
1053 touch_filename: /home/ubuntu/first-touch-1
1054 touch_filename2: /home/ubuntu/second-touch-1
1055 connection-point:
1056 - connection-point-id: vnf-mgmt
1057 id: vnf-mgmt
1058 name: vnf-mgmt
1059 - connection-point-id: vnf-data
1060 id: vnf-data
1061 name: vnf-data
1062 created-time: 1566823354.36234
1063 id: 88d90b0c-faff-4b9f-bccd-017f33985984
1064 ip-address: 10.205.1.46
1065 member-vnf-index-ref: '1'
1066 nsr-id-ref: f48163a6-c807-47bc-9682-f72caef5af85
1067 vdur:
1068 - _id: f0e7d7ce-2443-4dcb-ad0b-5ab9f3b13d37
1069 count-index: 0
1070 interfaces:
1071 - ip-address: 10.205.1.46
1072 mac-address: fa:16:3e:b4:3e:b1
1073 mgmt-vnf: true
1074 name: mgmtVM-eth0
1075 ns-vld-id: mgmt
1076 - ip-address: 192.168.54.2
1077 mac-address: fa:16:3e:6e:7e:78
1078 name: mgmtVM-eth1
1079 vnf-vld-id: internal
1080 internal-connection-point:
1081 - connection-point-id: mgmtVM-internal
1082 id: mgmtVM-internal
1083 name: mgmtVM-internal
1084 ip-address: 10.205.1.46
1085 name: ALF-1-mgmtVM-1
1086 status: ACTIVE
1087 status-detailed: null
1088 vdu-id-ref: mgmtVM
1089 vim-id: c2538499-4c30-41c0-acd5-80cb92f48061
1090 - _id: ab453219-2d9a-45c2-864d-2c0788385028
1091 count-index: 0
1092 interfaces:
1093 - ip-address: 192.168.54.3
1094 mac-address: fa:16:3e:d9:7a:5d
1095 name: dataVM-eth0
1096 vnf-vld-id: internal
1097 - ip-address: 192.168.24.3
1098 mac-address: fa:16:3e:d1:6c:0d
1099 name: dataVM-xe0
1100 ns-vld-id: datanet
1101 internal-connection-point:
1102 - connection-point-id: dataVM-internal
1103 id: dataVM-internal
1104 name: dataVM-internal
1105 ip-address: null
1106 name: ALF-1-dataVM-1
1107 status: ACTIVE
1108 status-detailed: null
1109 vdu-id-ref: dataVM
1110 vim-id: 87973c3f-365d-4227-95c2-7a8abc74349c
1111 vim-account-id: ea958ba5-4e58-4405-bf42-6e3be15d4c3a
1112 vld:
1113 - id: internal
1114 name: ALF-internal
1115 status: ACTIVE
1116 status-detailed: null
1117 vim-id: ff181e6d-2597-4244-b40b-bb0174bdfeb6
1118 vnfd-id: 7637bcf8-cf14-42dc-ad70-c66fcf1e6e77
1119 vnfd-ref: hackfest3charmed-vnf
1120 - _admin:
1121 created: 1566823354.3703845
1122 modified: 1566823354.3703845
1123 nsState: NOT_INSTANTIATED
1124 projects_read:
1125 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
1126 projects_write:
1127 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
1128 _id: 1ca3bb1a-b29b-49fe-bed6-5f3076d77434
1129 additionalParamsForVnf:
1130 touch_filename: /home/ubuntu/first-touch-2
1131 touch_filename2: /home/ubuntu/second-touch-2
1132 connection-point:
1133 - connection-point-id: vnf-mgmt
1134 id: vnf-mgmt
1135 name: vnf-mgmt
1136 - connection-point-id: vnf-data
1137 id: vnf-data
1138 name: vnf-data
1139 created-time: 1566823354.36234
1140 id: 1ca3bb1a-b29b-49fe-bed6-5f3076d77434
1141 ip-address: 10.205.1.47
1142 member-vnf-index-ref: '2'
1143 nsr-id-ref: f48163a6-c807-47bc-9682-f72caef5af85
1144 vdur:
1145 - _id: 190b4a2c-4f85-4cfe-9406-4cef7ffb1e67
1146 count-index: 0
1147 interfaces:
1148 - ip-address: 10.205.1.47
1149 mac-address: fa:16:3e:cb:9f:c7
1150 mgmt-vnf: true
1151 name: mgmtVM-eth0
1152 ns-vld-id: mgmt
1153 - ip-address: 192.168.231.1
1154 mac-address: fa:16:3e:1a:89:24
1155 name: mgmtVM-eth1
1156 vnf-vld-id: internal
1157 internal-connection-point:
1158 - connection-point-id: mgmtVM-internal
1159 id: mgmtVM-internal
1160 name: mgmtVM-internal
1161 ip-address: 10.205.1.47
1162 name: ALF-2-mgmtVM-1
1163 status: ACTIVE
1164 status-detailed: null
1165 vdu-id-ref: mgmtVM
1166 vim-id: 248077b2-e3b8-4a37-8b72-575abb8ed912
1167 - _id: 889b874d-e1c3-4e75-aa45-53a9b0ddabd9
1168 count-index: 0
1169 interfaces:
1170 - ip-address: 192.168.231.3
1171 mac-address: fa:16:3e:7e:ba:8c
1172 name: dataVM-eth0
1173 vnf-vld-id: internal
1174 - ip-address: 192.168.24.4
1175 mac-address: fa:16:3e:d2:e1:f5
1176 name: dataVM-xe0
1177 ns-vld-id: datanet
1178 internal-connection-point:
1179 - connection-point-id: dataVM-internal
1180 id: dataVM-internal
1181 name: dataVM-internal
1182 ip-address: null
1183 name: ALF-2-dataVM-1
1184 status: ACTIVE
1185 status-detailed: null
1186 vdu-id-ref: dataVM
1187 vim-id: a4ce4372-e0ad-4ae3-8f9f-1c969f32e77b
1188 vim-account-id: ea958ba5-4e58-4405-bf42-6e3be15d4c3a
1189 vld:
1190 - id: internal
1191 name: ALF-internal
1192 status: ACTIVE
1193 status-detailed: null
1194 vim-id: ff181e6d-2597-4244-b40b-bb0174bdfeb6
1195 vnfd-id: 7637bcf8-cf14-42dc-ad70-c66fcf1e6e77
1196 vnfd-ref: hackfest3charmed-vnf
1197 - _admin:
1198 created: 1575034637.009597
1199 modified: 1575034637.009597
1200 nsState: NOT_INSTANTIATED
1201 projects_read:
1202 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
1203 projects_write:
1204 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
1205 _id: 5ac34899-a23a-4b3c-918a-cd77acadbea6
1206 additionalParamsForVnf: null
1207 connection-point:
1208 - connection-point-id: null
1209 id: null
1210 name: mgmt
1211 created-time: 1575034636.9990137
1212 id: 5ac34899-a23a-4b3c-918a-cd77acadbea6
1213 ip-address: null
1214 k8s-cluster:
1215 nets:
1216 - external-connection-point-ref: mgmt
1217 id: mgmtnet
1218 ns-vld-id: mgmtnet
1219 vim_net: internal
1220 kdur:
1221 - ip-address: null
1222 k8s-cluster:
1223 id: e7169dab-f71a-4f1f-b82b-432605e8c4b3
1224 kdu-name: ldap
1225 helm-chart: stable/openldap:1.2.1
1226 - ip-address: null
1227 k8s-cluster:
1228 id: e7169dab-f71a-4f1f-b82b-432605e8c4b3
1229 kdu-name: mongo
1230 helm-chart: stable/mongodb
1231 member-vnf-index-ref: multikdu
1232 nsr-id-ref: 0bcb701c-ee4d-41ab-8ee6-f4156f7f114d
1233 vdur: []
1234 vim-account-id: 74337dcb-ef54-41e7-bd2d-8c0d7fcd326f
1235 vnfd-id: 7ab0d10d-8ce2-4c68-aef6-cc5a437a9c62
1236 vnfd-ref: multikdu_knf
1237 """
1238
1239 db_nslcmops_scale_text = """
1240 ---
1241 - _admin:
1242 created: 1565250912.2643092
1243 modified: 1570026174.83263
1244 projects_read:
1245 - d3581c99-31e3-45f9-b45c-49a290faedbc
1246 current_operation: '5'
1247 deployed:
1248 RO: d9aea288-b9b1-11e9-b19e-02420aff0006
1249 RO-account: d9bb2f1c-b9b1-11e9-b19e-02420aff0006
1250 detailed-status: Done
1251 modified: 1565250912.2643092
1252 operationalState: ENABLED
1253 operations:
1254 - member_vnf_index: '1'
1255 primitive: touch
1256 primitive_params: /home/ubuntu/last-touch-1
1257 operationState: COMPLETED
1258 detailed-status: Done
1259 - member_vnf_index: '1'
1260 primitive: touch
1261 primitive_params: /home/ubuntu/last-touch-2
1262 operationState: COMPLETED
1263 detailed-status: Done
1264 - member_vnf_index: '2'
1265 primitive: touch
1266 primitive_params: /home/ubuntu/last-touch-3
1267 operationState: COMPLETED
1268 detailed-status: Done
1269 projects_read:
1270 - b2d2ce4b-a1a0-4c01-847e-048632c43b40
1271 projects_write:
1272 - b2d2ce4b-a1a0-4c01-847e-048632c43b40
1273 worker: c4055a07655b
1274 deploy:
1275 RO: ACTION-1570026232.061742
1276 _id: 053967e8-7c1c-400f-ae82-3d45b291374b
1277 lcmOperationType: scale
1278 nsInstanceId: 90d9ebb7-2b5a-4b7c-bc34-a51fd7ef7b7b
1279 statusEnteredTime: 1570026243.09784
1280 startTime: 1570026174.8326
1281 operationParams:
1282 lcmOperationType: scale
1283 nsInstanceId: 90d9ebb7-2b5a-4b7c-bc34-a51fd7ef7b7b
1284 scaleVnfData:
1285 scaleByStepData:
1286 member-vnf-index: '1'
1287 scaling-group-descriptor: scale_scaling_group
1288 scaleVnfType: SCALE_IN
1289 scaleType: SCALE_VNF
1290 isAutomaticInvocation: false
1291 isCancelPending: false
1292 id: 053967e8-7c1c-400f-ae82-3d45b291374b
1293 links:
1294 nsInstance: "/osm/nslcm/v1/ns_instances/90d9ebb7-2b5a-4b7c-bc34-a51fd7ef7b7b"
1295 self: "/osm/nslcm/v1/ns_lcm_op_occs/053967e8-7c1c-400f-ae82-3d45b291374b"
1296 operationState: COMPLETED
1297 detailed-status: done
1298 """
1299
1300 test_ids = {
1301 # contains the ids of ns and operations of every test
1302 "TEST-A": {
1303 "ns": "f48163a6-c807-47bc-9682-f72caef5af85",
1304 "instantiate": "a639fac7-e0bb-4225-8ecb-c1f8efcc125e",
1305 "terminate": "a639fac7-e0bb-4225-ffff-c1f8efcc125e",
1306 },
1307 "TEST-KDU": {
1308 "ns": "0bcb701c-ee4d-41ab-8ee6-f4156f7f114d",
1309 "instantiate": "cf3aa178-7640-4174-b921-2330e6f2aad6",
1310 "terminate": None,
1311 }
1312 }