Feature-9904: Enhancing NG-UI to enable Juju operational view dashboard
[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 K8s: []
230 RO:
231 nsd_id: 876573b5-968d-40b9-b52b-91bf5c5844f7
232 nsr_id: c9fe9908-3180-430d-b633-fca2f68db008
233 nsr_status: ACTIVE
234 vnfd:
235 - id: 1ab2a418-9fe3-4358-bf17-411e5155535f
236 member-vnf-index: '1'
237 - id: 0de348e3-c201-4f6a-91cc-7f957e2d5504
238 member-vnf-index: '2'
239 VCA:
240 - application: alf-b-aa
241 ee_id: f48163a6-c807-47bc-9682-f72caef5af85.alf-b-aa
242 needed_terminate: True
243 detailed-status: Ready!
244 member-vnf-index: '1'
245 model: f48163a6-c807-47bc-9682-f72caef5af85
246 operational-status: active
247 primitive_id: null
248 ssh-public-key: ssh-rsa pub-key root@juju-145d3e-0
249 step: ssh-public-key-obtained
250 vdu_count_index: null
251 vdu_id: null
252 vdu_name: null
253 vnfd_id: hackfest3charmed-vnf
254 - application: alf-c-ab
255 ee_id: f48163a6-c807-47bc-9682-f72caef5af85.alf-c-ab
256 needed_terminate: True
257 detailed-status: Ready!
258 member-vnf-index: '2'
259 model: f48163a6-c807-47bc-9682-f72caef5af85
260 operational-status: active
261 primitive_id: null
262 ssh-public-key: ssh-rsa pub-key root@juju-145d3e-0
263 step: ssh-public-key-obtained
264 vdu_count_index: null
265 vdu_id: null
266 vdu_name: null
267 vnfd_id: hackfest3charmed-vnf
268 VCA-model-name: f48163a6-c807-47bc-9682-f72caef5af85
269 modified: 1566823354.3716335
270 nsState: INSTANTIATED
271 nslcmop: null
272 projects_read:
273 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
274 projects_write:
275 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
276 _id: f48163a6-c807-47bc-9682-f72caef5af85
277 additionalParamsForNs: null
278 admin-status: ENABLED
279 config-status: init
280 constituent-vnfr-ref:
281 - 88d90b0c-faff-4b9f-bccd-017f33985984
282 - 1ca3bb1a-b29b-49fe-bed6-5f3076d77434
283 create-time: 1566823354.36234
284 datacenter: ea958ba5-4e58-4405-bf42-6e3be15d4c3a
285 description: default description
286 vcaStatus:
287 8c707f16-2d9b-49d6-af5e-2ce9985b2adf:
288 applications:
289 app-vnf-1fb8538dfc39:
290 can_upgrade_to: ''
291 charm: 'local:xenial/simple-1'
292 charm_profile: ''
293 charm_version: ''
294 endpoint_bindings: null
295 err: null
296 exposed: false
297 int_: null
298 life: ''
299 meter_statuses: { }
300 provider_id: null
301 public_address: ''
302 relations: { }
303 series: xenial
304 status:
305 data: { }
306 err: null
307 info: Ready!
308 kind: ''
309 life: ''
310 since: '2021-02-17T08:39:54.239185095Z'
311 status: active
312 unknown_fields: { }
313 version: ''
314 subordinate_to: [ ]
315 units:
316 app-vnf-1fb8538dfc39/0:
317 address: null
318 agent_status:
319 data: { }
320 err: null
321 info: ''
322 kind: ''
323 life: ''
324 since: '2021-02-17T08:52:18.077155028Z'
325 status: idle
326 unknown_fields: { }
327 version: 2.8.1
328 charm: ''
329 leader: true
330 machine: '0'
331 opened_ports: null
332 provider_id: null
333 public_address: 10.151.40.53
334 subordinates: { }
335 unknown_fields: { }
336 workload_status:
337 data: { }
338 err: null
339 info: Ready!
340 kind: ''
341 life: ''
342 since: '2021-02-17T08:39:54.239185095Z'
343 status: active
344 unknown_fields: { }
345 version: ''
346 workload_version: ''
347 unknown_fields:
348 charm-verion: ''
349 workload_version: ''
350 actions:
351 generate-ssh-key: >-
352 Generate a new SSH keypair for this unit. This will replace any
353 existing previously generated keypair.
354 get-ssh-public-key: Get the public SSH key for this unit.
355 reboot: Reboot the VNF virtual machine.
356 restart: Stop the service on the VNF.
357 run: Run an arbitrary command
358 start: Stop the service on the VNF.
359 stop: Stop the service on the VNF.
360 touch: Touch a file on the VNF.
361 upgrade: Upgrade the software on the VNF.
362 verify-ssh-credentials: >-
363 Verify that this unit can authenticate with server specified by
364 ssh-hostname and ssh-username.
365 configs:
366 boolean-option:
367 default: false
368 description: A short description of the configuration option
369 source: default
370 type: boolean
371 value: false
372 int-option:
373 default: 9001
374 description: A short description of the configuration option
375 source: default
376 type: int
377 value: 9001
378 ssh-hostname:
379 default: ''
380 description: The hostname or IP address of the machine to
381 source: user
382 type: string
383 value: 192.168.61.90
384 ssh-key-bits:
385 default: 4096
386 description: The number of bits to use for the SSH key.
387 source: default
388 type: int
389 value: 4096
390 ssh-key-type:
391 default: rsa
392 description: The type of encryption to use for the SSH key.
393 source: default
394 type: string
395 value: rsa
396 ssh-password:
397 default: ''
398 description: The password used to authenticate.
399 source: user
400 type: string
401 value: osm4u
402 ssh-private-key:
403 default: ''
404 description: DEPRECATED. The private ssh key to be used to authenticate.
405 source: default
406 type: string
407 value: ''
408 ssh-public-key:
409 default: ''
410 description: The public key of this unit.
411 source: default
412 type: string
413 value: ''
414 ssh-username:
415 default: ''
416 description: The username to login as.
417 source: user
418 type: string
419 value: ubuntu
420 string-option:
421 default: Default Value
422 description: A short description of the configuration option
423 source: default
424 type: string
425 value: Default Value
426 app-vnf-943ab4274bb6:
427 can_upgrade_to: ''
428 charm: 'local:xenial/simple-0'
429 charm_profile: ''
430 charm_version: ''
431 endpoint_bindings: null
432 err: null
433 exposed: false
434 int_: null
435 life: ''
436 meter_statuses: { }
437 provider_id: null
438 public_address: ''
439 relations: { }
440 series: xenial
441 status:
442 data: { }
443 err: null
444 info: Ready!
445 kind: ''
446 life: ''
447 since: '2021-02-17T08:39:15.165682713Z'
448 status: active
449 unknown_fields: { }
450 version: ''
451 subordinate_to: [ ]
452 units:
453 app-vnf-943ab4274bb6/0:
454 address: null
455 agent_status:
456 data: { }
457 err: null
458 info: ''
459 kind: ''
460 life: ''
461 since: '2021-02-17T08:46:06.473054303Z'
462 status: idle
463 unknown_fields: { }
464 version: 2.8.1
465 charm: ''
466 leader: true
467 machine: '1'
468 opened_ports: null
469 provider_id: null
470 public_address: 10.151.40.117
471 subordinates: { }
472 unknown_fields: { }
473 workload_status:
474 data: { }
475 err: null
476 info: Ready!
477 kind: ''
478 life: ''
479 since: '2021-02-17T08:39:15.165682713Z'
480 status: active
481 unknown_fields: { }
482 version: ''
483 workload_version: ''
484 unknown_fields:
485 charm-verion: ''
486 workload_version: ''
487 actions:
488 generate-ssh-key: >-
489 Generate a new SSH keypair for this unit. This will replace any
490 existing previously generated keypair.
491 get-ssh-public-key: Get the public SSH key for this unit.
492 reboot: Reboot the VNF virtual machine.
493 restart: Stop the service on the VNF.
494 run: Run an arbitrary command
495 start: Stop the service on the VNF.
496 stop: Stop the service on the VNF.
497 touch: Touch a file on the VNF.
498 upgrade: Upgrade the software on the VNF.
499 verify-ssh-credentials: >-
500 Verify that this unit can authenticate with server specified by
501 ssh-hostname and ssh-username.
502 configs:
503 boolean-option:
504 default: false
505 description: A short description of the configuration option
506 source: default
507 type: boolean
508 value: false
509 int-option:
510 default: 9001
511 description: A short description of the configuration option
512 source: default
513 type: int
514 value: 9001
515 ssh-hostname:
516 default: ''
517 description: The hostname or IP address of the machine to
518 source: user
519 type: string
520 value: 192.168.61.72
521 ssh-key-bits:
522 default: 4096
523 description: The number of bits to use for the SSH key.
524 source: default
525 type: int
526 value: 4096
527 ssh-key-type:
528 default: rsa
529 description: The type of encryption to use for the SSH key.
530 source: default
531 type: string
532 value: rsa
533 ssh-password:
534 default: ''
535 description: The password used to authenticate.
536 source: user
537 type: string
538 value: osm4u
539 ssh-private-key:
540 default: ''
541 description: DEPRECATED. The private ssh key to be used to authenticate.
542 source: default
543 type: string
544 value: ''
545 ssh-public-key:
546 default: ''
547 description: The public key of this unit.
548 source: default
549 type: string
550 value: ''
551 ssh-username:
552 default: ''
553 description: The username to login as.
554 source: user
555 type: string
556 value: ubuntu
557 string-option:
558 default: Default Value
559 description: A short description of the configuration option
560 source: default
561 type: string
562 value: Default Value
563 branches: { }
564 controller_timestamp: '2021-02-17T09:17:38.006569064Z'
565 machines:
566 '0':
567 agent_status:
568 data: { }
569 err: null
570 info: ''
571 kind: ''
572 life: ''
573 since: '2021-02-17T08:37:46.637167056Z'
574 status: started
575 unknown_fields: { }
576 version: 2.8.1
577 constraints: ''
578 containers: { }
579 display_name: ''
580 dns_name: 10.151.40.53
581 hardware: arch=amd64 cores=0 mem=0M
582 has_vote: false
583 id_: '0'
584 instance_id: juju-0f027b-0
585 instance_status:
586 data: { }
587 err: null
588 info: Running
589 kind: ''
590 life: ''
591 since: '2021-02-17T08:35:58.435458338Z'
592 status: running
593 unknown_fields: { }
594 version: ''
595 ip_addresses:
596 - 10.151.40.53
597 jobs:
598 - JobHostUnits
599 lxd_profiles: { }
600 modification_status:
601 data: { }
602 err: null
603 info: ''
604 kind: ''
605 life: ''
606 since: '2021-02-17T08:35:34.663795891Z'
607 status: idle
608 unknown_fields: { }
609 version: ''
610 network_interfaces:
611 eth0:
612 dns_nameservers: null
613 gateway: 10.151.40.1
614 ip_addresses:
615 - 10.151.40.53
616 is_up: true
617 mac_address: '00:16:3e:99:bf:c7'
618 space: null
619 unknown_fields: { }
620 primary_controller_machine: null
621 series: xenial
622 unknown_fields: { }
623
624 wants_vote: false
625 '1':
626 agent_status:
627 data: { }
628 err: null
629 info: ''
630 kind: ''
631 life: ''
632 since: '2021-02-17T08:37:00.893313184Z'
633 status: started
634 unknown_fields: { }
635 version: 2.8.1
636 constraints: ''
637 containers: { }
638 display_name: ''
639 dns_name: 10.151.40.117
640 hardware: arch=amd64 cores=0 mem=0M
641 has_vote: false
642 id_: '1'
643 instance_id: juju-0f027b-1
644 instance_status:
645 data: { }
646 err: null
647 info: Running
648 kind: ''
649 life: ''
650 since: '2021-02-17T08:36:23.354547217Z'
651 status: running
652 unknown_fields: { }
653 version: ''
654 ip_addresses:
655 - 10.151.40.117
656 jobs:
657 - JobHostUnits
658 lxd_profiles: { }
659 modification_status:
660 data: { }
661 err: null
662 info: ''
663 kind: ''
664 life: ''
665 since: '2021-02-17T08:35:34.768829507Z'
666 status: idle
667 unknown_fields: { }
668 version: ''
669 network_interfaces:
670 eth0:
671 dns_nameservers: null
672 gateway: 10.151.40.1
673 ip_addresses:
674 - 10.151.40.117
675 is_up: true
676 mac_address: '00:16:3e:99:fe:1c'
677 space: null
678 unknown_fields: { }
679 primary_controller_machine: null
680 series: xenial
681 unknown_fields: { }
682 wants_vote: false
683 model:
684 available_version: ''
685 cloud_tag: cloud-localhost
686 migration: null
687 name: 7c707f16-2d9b-49d6-af5e-2ce9985b2adf
688 region: localhost
689 unknown_fields:
690 meter-status:
691 color: ''
692 message: ''
693 model-status:
694 data: { }
695 info: ''
696 kind: ''
697
698 life: ''
699 since: '2021-02-17T08:35:31.856691457Z'
700 status: available
701 version: ''
702 sla: unsupported
703 type: iaas
704 version: 2.8.1
705 offers: { }
706 relations: [ ]
707 remote_applications: { }
708 unknown_fields: { }
709 executedActions:
710 - id: '6'
711 action: touch
712 status: completed
713 Code: '0'
714 output: ''
715 - id: '4'
716 action: touch
717 status: completed
718 Code: '0'
719 output: ''
720 - id: '2'
721 action: verify-ssh-credentials
722 status: completed
723 Code: '0'
724 output: ALF-1-mgmtvm-1
725 verified: 'True'
726 detailed-status: 'ERROR executing proxy charm initial primitives for member_vnf_index=1
727 vdu_id=None: charm error executing primitive verify-ssh-credentials for member_vnf_index=1
728 vdu_id=None: ''timeout after 600 seconds'''
729 id: f48163a6-c807-47bc-9682-f72caef5af85
730 instantiate_params:
731 nsDescription: default description
732 nsName: ALF
733 nsdId: 8c2f8b95-bb1b-47ee-8001-36dc090678da
734 vimAccountId: ea958ba5-4e58-4405-bf42-6e3be15d4c3a
735 name: ALF
736 name-ref: ALF
737 ns-instance-config-ref: f48163a6-c807-47bc-9682-f72caef5af85
738 nsd:
739 _admin:
740 created: 1566823353.971486
741 modified: 1566823353.971486
742 onboardingState: ONBOARDED
743 operationalState: ENABLED
744 projects_read:
745 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
746 projects_write:
747 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
748 storage:
749 descriptor: hackfest_3charmed_nsd/hackfest_3charmed_nsd.yaml
750 folder: 8c2f8b95-bb1b-47ee-8001-36dc090678da
751 fs: local
752 path: /app/storage/
753 pkg-dir: hackfest_3charmed_nsd
754 zipfile: package.tar.gz
755 usageState: NOT_IN_USE
756 userDefinedData: {}
757 _id: 8c2f8b95-bb1b-47ee-8001-36dc090678da
758 constituent-vnfd:
759 - member-vnf-index: '1'
760 vnfd-id-ref: hackfest3charmed-vnf
761 - member-vnf-index: '2'
762 vnfd-id-ref: hackfest3charmed-vnf
763 description: NS with 2 VNFs hackfest3charmed-vnf connected by datanet and
764 mgmtnet VLs
765 id: hackfest3charmed-ns
766 logo: osm.png
767 name: hackfest3charmed-ns
768 short-name: hackfest3charmed-ns
769 version: '1.0'
770 vld:
771 - id: mgmt
772 mgmt-network: true
773 name: mgmt
774 short-name: mgmt
775 type: ELAN
776 vim-network-name: mgmt
777 vnfd-connection-point-ref:
778 - member-vnf-index-ref: '1'
779 vnfd-connection-point-ref: vnf-mgmt
780 vnfd-id-ref: hackfest3charmed-vnf
781 - member-vnf-index-ref: '2'
782 vnfd-connection-point-ref: vnf-mgmt
783 vnfd-id-ref: hackfest3charmed-vnf
784 - id: datanet
785 name: datanet
786 short-name: datanet
787 type: ELAN
788 vnfd-connection-point-ref:
789 - member-vnf-index-ref: '1'
790 vnfd-connection-point-ref: vnf-data
791 vnfd-id-ref: hackfest3charmed-vnf
792 - member-vnf-index-ref: '2'
793 vnfd-connection-point-ref: vnf-data
794 vnfd-id-ref: hackfest3charmed-vnf
795 nsd-id: 8c2f8b95-bb1b-47ee-8001-36dc090678da
796 nsd-name-ref: hackfest3charmed-ns
797 nsd-ref: hackfest3charmed-ns
798 operational-events: []
799 operational-status: failed
800 orchestration-progress: {}
801 resource-orchestrator: osmopenmano
802 short-name: ALF
803 ssh-authorized-key: null
804 vld:
805 - id: mgmt
806 name: null
807 status: ACTIVE
808 status-detailed: null
809 vim-id: f99ae780-0e2f-4985-af41-574eae6919c0
810 vim-network-name: mgmt
811 - id: datanet
812 name: ALF-datanet
813 status: ACTIVE
814 status-detailed: null
815 vim-id: c31364ba-f573-4ab6-bf1a-fed30ede39a8
816 vnfd-id:
817 - 7637bcf8-cf14-42dc-ad70-c66fcf1e6e77
818 - _admin:
819 created: 1575034637.011233
820 current-operation: null
821 deployed:
822 K8s:
823 - k8scluster-uuid: 73d96432-d692-40d2-8440-e0c73aee209c
824 kdu-instance: stable-mongodb-0086856106
825 kdu-model: stable/mongodb
826 kdu-name: mongo
827 vnfr-id: 5ac34899-a23a-4b3c-918a-cd77acadbea6
828 - k8scluster-uuid: 73d96432-d692-40d2-8440-e0c73aee209c
829 kdu-instance: stable-openldap-0092830263
830 kdu-model: stable/mongodb
831 kdu-name: mongo
832 vnfr-id: 5ac34899-a23a-4b3c-918a-cd77acadbea6
833 RO:
834 detailed-status: Deployed at VIM
835 nsd_id: b03a8de8-1898-4142-bc6d-3b0787df567d
836 nsr_id: b5ce3e00-8647-415d-afaa-d5a612cf3074
837 nsr_status: ACTIVE
838 operational-status: running
839 vnfd:
840 - id: b9493dae-a4c9-4b96-8965-329581efb0a1
841 member-vnf-index: multikdu
842 VCA: []
843 modified: 1575034637.011233
844 nsState: INSTANTIATED
845 nslcmop: null
846 operation-type: null
847 projects_read:
848 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
849 projects_write:
850 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
851 _id: 0bcb701c-ee4d-41ab-8ee6-f4156f7f114d
852 additionalParamsForNs: null
853 admin-status: ENABLED
854 config-status: configured
855 constituent-vnfr-ref:
856 - 5ac34899-a23a-4b3c-918a-cd77acadbea6
857 create-time: 1575034636.9990137
858 datacenter: ea958ba5-4e58-4405-bf42-6e3be15d4c3a
859 description: default description
860 vcaStatus: {}
861 detailed-status: done
862 id: 0bcb701c-ee4d-41ab-8ee6-f4156f7f114d
863 instantiate_params:
864 nsDescription: default description
865 nsName: multikdu
866 nsdId: d0f63683-9032-4c6f-8928-ffd4674b9f69
867 vimAccountId: 74337dcb-ef54-41e7-bd2d-8c0d7fcd326f
868 name: multikdu
869 name-ref: multikdu
870 ns-instance-config-ref: 0bcb701c-ee4d-41ab-8ee6-f4156f7f114d
871 nsd-id: d0f63683-9032-4c6f-8928-ffd4674b9f69
872 nsd-name-ref: multikdu_ns
873 nsd-ref: multikdu_ns
874 operational-events: []
875 operational-status: init
876 orchestration-progress: {}
877 resource-orchestrator: osmopenmano
878 short-name: multikdu
879 ssh-authorized-key: null
880 vld:
881 - id: mgmtnet
882 name: null
883 status: ACTIVE
884 status-detailed: null
885 vim-id: 9b6a2ac4-767e-4ec9-9497-8ba63084c77f
886 vim-network-name: mgmt
887 vnfd-id:
888 - 7ab0d10d-8ce2-4c68-aef6-cc5a437a9c62
889 """
890
891 ro_ns_text = """
892 datacenter_tenant_id: dc5c67fa-c7f2-11e9-b9c0-02420aff0004
893 description: null
894 name: ALF
895 classifications: []
896 sdn_nets: []
897 nets:
898 - created: false
899 datacenter_id: dc51ce6c-c7f2-11e9-b9c0-02420aff0004
900 datacenter_tenant_id: dc5c67fa-c7f2-11e9-b9c0-02420aff0004
901 error_msg: null
902 ns_net_osm_id: mgmt
903 related: c6bac394-fa27-4c43-bb34-42f621a9d343
904 sce_net_id: 8f215bab-c35e-41e6-a035-42bfaa07af9f
905 sdn_net_id: null
906 status: ACTIVE
907 uuid: c6bac394-fa27-4c43-bb34-42f621a9d343
908 vim_info: "{vim_info: null}"
909 vim_name: null
910 vim_net_id: f99ae780-0e2f-4985-af41-574eae6919c0
911 vnf_net_id: null
912 vnf_net_osm_id: null
913 - created: true
914 datacenter_id: dc51ce6c-c7f2-11e9-b9c0-02420aff0004
915 datacenter_tenant_id: dc5c67fa-c7f2-11e9-b9c0-02420aff0004
916 error_msg: null
917 ns_net_osm_id: datanet
918 related: 509d576c-120f-493a-99a1-5fea99dfe041
919 sce_net_id: 3d766bbc-33a8-41aa-a986-2f35e8d25c16
920 sdn_net_id: null
921 status: ACTIVE
922 uuid: 509d576c-120f-493a-99a1-5fea99dfe041
923 vim_info: "{vim_info: null}"
924 vim_name: ALF-datanet
925 vim_net_id: c31364ba-f573-4ab6-bf1a-fed30ede39a8
926 vnf_net_id: null
927 vnf_net_osm_id: null
928 - created: true
929 datacenter_id: dc51ce6c-c7f2-11e9-b9c0-02420aff0004
930 datacenter_tenant_id: dc5c67fa-c7f2-11e9-b9c0-02420aff0004
931 error_msg: null
932 ns_net_osm_id: null
933 related: 277fed09-3220-4bfd-9052-b96b21a32daf
934 sce_net_id: null
935 sdn_net_id: null
936 status: ACTIVE
937 uuid: 277fed09-3220-4bfd-9052-b96b21a32daf
938 vim_info: "{vim_info: null}"
939 vim_name: ALF-internal
940 vim_net_id: ff181e6d-2597-4244-b40b-bb0174bdfeb6
941 vnf_net_id: 62e62fae-c12b-4ebc-9a9b-30031c6c16fa
942 vnf_net_osm_id: internal
943 - created: true
944 datacenter_id: dc51ce6c-c7f2-11e9-b9c0-02420aff0004
945 datacenter_tenant_id: dc5c67fa-c7f2-11e9-b9c0-02420aff0004
946 error_msg: null
947 ns_net_osm_id: null
948 related: 92534d1a-e697-4372-a84d-aa0aa643b68a
949 sce_net_id: null
950 sdn_net_id: null
951 status: ACTIVE
952 uuid: 92534d1a-e697-4372-a84d-aa0aa643b68a
953 vim_info: "{vim_info: null}"
954 vim_name: ALF-internal
955 vim_net_id: 09655387-b639-421a-b5f6-72b26d685fb4
956 vnf_net_id: 13c6c77d-86a5-4914-832c-990d4ec7b54e
957 vnf_net_osm_id: internal
958 nsd_osm_id: f48163a6-c807-47bc-9682-f72caef5af85.2.hackfest3charmed-ns
959 scenario_id: 876573b5-968d-40b9-b52b-91bf5c5844f7
960 scenario_name: hackfest3charmed-ns
961 sfis: []
962 sfps: []
963 sfs: []
964 tenant_id: 0ea38bd0-2729-47a9-ae07-c6ce76115eb2
965 uuid: c9fe9908-3180-430d-b633-fca2f68db008
966 vnfs:
967 - datacenter_id: dc51ce6c-c7f2-11e9-b9c0-02420aff0004
968 datacenter_tenant_id: dc5c67fa-c7f2-11e9-b9c0-02420aff0004
969 ip_address: 10.205.1.46
970 member_vnf_index: '1'
971 mgmt_access: '{interface_id: 61549ee3-cd6c-4930-8b90-eaad97fe345b, required: ''False'',
972 vm_id: 6cf4a48f-3b6c-4395-8221-119fa37de24a}
973
974 '
975 sce_vnf_id: 83be04a8-c513-42ba-9908-22728f686d31
976 uuid: 94724042-7576-4fb0-82ec-6a7ab642741c
977 vms:
978 - created_at: '2019-08-26T12:50:38'
979 error_msg: null
980 interfaces:
981 - external_name: vnf-mgmt
982 instance_net_id: c6bac394-fa27-4c43-bb34-42f621a9d343
983 internal_name: mgmtVM-eth0
984 ip_address: 10.205.1.46
985 mac_address: fa:16:3e:b4:3e:b1
986 sdn_port_id: null
987 type: mgmt
988 vim_info: "{vim_info: null}"
989 vim_interface_id: 4d3cb8fd-7040-4169-a0ad-2486d2b006a1
990 - external_name: null
991 instance_net_id: 277fed09-3220-4bfd-9052-b96b21a32daf
992 internal_name: mgmtVM-eth1
993 ip_address: 192.168.54.2
994 mac_address: fa:16:3e:6e:7e:78
995 sdn_port_id: null
996 type: bridge
997 vim_info: "{vim_info: null}"
998 vim_interface_id: 54ed68e2-9802-4dfe-b68a-280b3fc6e02d
999 ip_address: 10.205.1.46
1000 name: mgmtVM
1001 related: d0b91293-a91d-4f08-b15f-0bf841216dfe
1002 status: ACTIVE
1003 uuid: d0b91293-a91d-4f08-b15f-0bf841216dfe
1004 vdu_osm_id: mgmtVM
1005 vim_info: "{vim_info: null}"
1006 vim_name: ALF-1-mgmtVM-1
1007 vim_vm_id: c2538499-4c30-41c0-acd5-80cb92f48061
1008 - created_at: '2019-08-26T12:50:38'
1009 error_msg: null
1010 interfaces:
1011 - external_name: null
1012 instance_net_id: 277fed09-3220-4bfd-9052-b96b21a32daf
1013 internal_name: dataVM-eth0
1014 ip_address: 192.168.54.3
1015 mac_address: fa:16:3e:d9:7a:5d
1016 sdn_port_id: null
1017 type: bridge
1018 vim_info: "{vim_info: null}"
1019 vim_interface_id: 1637f350-8840-4241-8ed0-4616bdcecfcf
1020 - external_name: vnf-data
1021 instance_net_id: 509d576c-120f-493a-99a1-5fea99dfe041
1022 internal_name: dataVM-xe0
1023 ip_address: 192.168.24.3
1024 mac_address: fa:16:3e:d1:6c:0d
1025 sdn_port_id: null
1026 type: bridge
1027 vim_info: "{vim_info: null}"
1028 vim_interface_id: 54c73e83-7059-41fe-83a9-4c4ae997b481
1029 name: dataVM
1030 related: 5c08253d-8a35-474f-b0d3-c5297d174c13
1031 status: ACTIVE
1032 uuid: 5c08253d-8a35-474f-b0d3-c5297d174c13
1033 vdu_osm_id: dataVM
1034 vim_info: "{vim_info: null}"
1035 vim_name: ALF-1-dataVM-1
1036 vim_vm_id: 87973c3f-365d-4227-95c2-7a8abc74349c
1037 - created_at: '2019-08-26T13:40:54'
1038 error_msg: null
1039 interfaces:
1040 - external_name: null
1041 instance_net_id: 277fed09-3220-4bfd-9052-b96b21a32daf
1042 internal_name: dataVM-eth0
1043 ip_address: 192.168.54.5
1044 mac_address: fa:16:3e:e4:17:45
1045 sdn_port_id: null
1046 type: bridge
1047 vim_info: "{vim_info: null}"
1048 vim_interface_id: 7e246e40-8710-4c33-9c95-78fc3c02bc5b
1049 - external_name: vnf-data
1050 instance_net_id: 509d576c-120f-493a-99a1-5fea99dfe041
1051 internal_name: dataVM-xe0
1052 ip_address: 192.168.24.5
1053 mac_address: fa:16:3e:29:6f:a6
1054 sdn_port_id: null
1055 type: bridge
1056 vim_info: "{vim_info: null}"
1057 vim_interface_id: ce81af7a-9adf-494b-950e-6581fd04ecc4
1058 name: dataVM
1059 related: 1ae5a0a2-c15a-49a4-a77c-2991d97f6dbe
1060 status: ACTIVE
1061 uuid: 1ae5a0a2-c15a-49a4-a77c-2991d97f6dbe
1062 vdu_osm_id: dataVM
1063 vim_info: "{vim_info: null}"
1064 vim_name: ALF-1-dataVM-2
1065 vim_vm_id: 4916533e-36c6-4861-9fe3-366a8fb0a5f8
1066 vnf_id: 1ab2a418-9fe3-4358-bf17-411e5155535f
1067 vnf_name: hackfest3charmed-vnf.1
1068 vnfd_osm_id: f48163a6-c807-47bc-9682-f72caef5af85.0.1
1069 - datacenter_id: dc51ce6c-c7f2-11e9-b9c0-02420aff0004
1070 datacenter_tenant_id: dc5c67fa-c7f2-11e9-b9c0-02420aff0004
1071 ip_address: 10.205.1.47
1072 member_vnf_index: '2'
1073 mgmt_access: '{interface_id: 538604c3-5c5e-41eb-8f84-c0239c7fabcd, required: ''False'',
1074 vm_id: dd04d792-05c9-4ecc-bf28-f77384d00311}
1075
1076 '
1077 sce_vnf_id: c4f3607a-08ff-4f75-893c-fce507e2f240
1078 uuid: 00020403-e80f-4ef2-bb7e-b29669643035
1079 vms:
1080 - created_at: '2019-08-26T12:50:38'
1081 error_msg: null
1082 interfaces:
1083 - external_name: vnf-mgmt
1084 instance_net_id: c6bac394-fa27-4c43-bb34-42f621a9d343
1085 internal_name: mgmtVM-eth0
1086 ip_address: 10.205.1.47
1087 mac_address: fa:16:3e:cb:9f:c7
1088 sdn_port_id: null
1089 type: mgmt
1090 vim_info: "{vim_info: null}"
1091 vim_interface_id: dcd6d2de-3c68-481c-883e-e9d38c671dc4
1092 - external_name: null
1093 instance_net_id: 92534d1a-e697-4372-a84d-aa0aa643b68a
1094 internal_name: mgmtVM-eth1
1095 ip_address: 192.168.231.1
1096 mac_address: fa:16:3e:1a:89:24
1097 sdn_port_id: null
1098 type: bridge
1099 vim_info: "{vim_info: null}"
1100 vim_interface_id: 50e538e3-aba0-4652-93bb-20487f3f28e1
1101 ip_address: 10.205.1.47
1102 name: mgmtVM
1103 related: 4543ab5d-578c-427c-9df2-affd17e21b66
1104 status: ACTIVE
1105 uuid: 4543ab5d-578c-427c-9df2-affd17e21b66
1106 vdu_osm_id: mgmtVM
1107 vim_info: "{vim_info: null}"
1108 vim_name: ALF-2-mgmtVM-1
1109 vim_vm_id: 248077b2-e3b8-4a37-8b72-575abb8ed912
1110 - created_at: '2019-08-26T12:50:38'
1111 error_msg: null
1112 interfaces:
1113 - external_name: null
1114 instance_net_id: 92534d1a-e697-4372-a84d-aa0aa643b68a
1115 internal_name: dataVM-eth0
1116 ip_address: 192.168.231.3
1117 mac_address: fa:16:3e:7e:ba:8c
1118 sdn_port_id: null
1119 type: bridge
1120 vim_info: "{vim_info: null}"
1121 vim_interface_id: 15274862-14ea-4527-b405-101cae8bc1a0
1122 - external_name: vnf-data
1123 instance_net_id: 509d576c-120f-493a-99a1-5fea99dfe041
1124 internal_name: dataVM-xe0
1125 ip_address: 192.168.24.4
1126 mac_address: fa:16:3e:d2:e1:f5
1127 sdn_port_id: null
1128 type: bridge
1129 vim_info: "{vim_info: null}"
1130 vim_interface_id: 253ebe4e-38d5-46be-8777-dbb57510a2ec
1131 name: dataVM
1132 related: 6f03f16b-295a-47a1-9a69-2d069d574a33
1133 status: ACTIVE
1134 uuid: 6f03f16b-295a-47a1-9a69-2d069d574a33
1135 vdu_osm_id: dataVM
1136 vim_info: "{vim_info: null}"
1137 vim_name: ALF-2-dataVM-1
1138 vim_vm_id: a4ce4372-e0ad-4ae3-8f9f-1c969f32e77b
1139 vnf_id: 0de348e3-c201-4f6a-91cc-7f957e2d5504
1140 vnf_name: hackfest3charmed-vnf.2
1141 vnfd_osm_id: f48163a6-c807-47bc-9682-f72caef5af85.1.2
1142 """
1143
1144 ro_delete_action_text = """
1145 actions:
1146 - created_at: 1580140763.1099188
1147 description: DELETE
1148 instance_id: c9fe9908-3180-430d-b633-fca2f68db008
1149 modified_at: 1580140763.253148
1150 number_done: 1
1151 number_failed: 0
1152 number_tasks: 1
1153 tenant_id: 0ea38bd0-2729-47a9-ae07-c6ce76115eb2
1154 uuid: delete
1155 vim_wim_actions:
1156 - action: DELETE
1157 created_at: 1580140763.1099188
1158 datacenter_vim_id: dc5c67fa-c7f2-11e9-b9c0-02420aff0004
1159 error_msg: null
1160 extra: '{params: [9b6a2ac4-767e-4ec9-9497-8ba63084c77f, null]}'
1161 instance_action_id: ACTION-1580140763.054037
1162 item: instance_nets
1163 item_id: 8cb06b72-c71d-4b58-b419-95025fa651d3
1164 modified_at: 1580140763.1099188
1165 related: 8cb06b72-c71d-4b58-b419-95025fa651d3
1166 status: SUPERSEDED
1167 task_index: 0
1168 vim_id: null
1169 wim_account_id: null
1170 wim_internal_id: null
1171 worker: null
1172 """
1173
1174 db_vim_accounts_text = """
1175 ---
1176 - _admin:
1177 created: 1566818150.3024442
1178 current_operation: 0
1179 deployed:
1180 RO: dc51ce6c-c7f2-11e9-b9c0-02420aff0004
1181 RO-account: dc5c67fa-c7f2-11e9-b9c0-02420aff0004
1182 detailed-status: Done
1183 modified: 1566818150.3024442
1184 operationalState: ENABLED
1185 operations:
1186 - detailed-status: Done
1187 lcmOperationType: create
1188 operationParams: null
1189 operationState: COMPLETED
1190 startTime: 1566818150.3025382
1191 statusEnteredTime: 1566818150.3025382
1192 worker: 86434c2948e2
1193 projects_read:
1194 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
1195 projects_write:
1196 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
1197 _id: ea958ba5-4e58-4405-bf42-6e3be15d4c3a
1198 description: some description here
1199 name: vim1
1200 schema_version: '1.1'
1201 vim_password: 5g0yGX86qIhprX86YTMcpg==
1202 vim_tenant_name: osm
1203 vim_type: openstack
1204 vim_url: http://10.95.87.162:5000/v2.0
1205 vim_user: osm
1206 - _admin:
1207 created: 1566818150.3024442
1208 current_operation: 0
1209 deployed:
1210 RO: 9ac17c0d-4265-4333-843b-c3cbd1f93f88
1211 RO-account: 011895dc-ab34-4c9f-b06f-401a8ffb073b
1212 detailed-status: Done
1213 modified: 1566818150.3024442
1214 operationalState: ENABLED
1215 operations:
1216 - detailed-status: Done
1217 lcmOperationType: create
1218 operationParams: null
1219 operationState: COMPLETED
1220 startTime: 1566818150.3025382
1221 statusEnteredTime: 1566818150.3025382
1222 worker: 86434c2948e2
1223 projects_read:
1224 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
1225 projects_write:
1226 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
1227 _id: 05357241-1a01-416f-9e02-af20f65f51cd
1228 description: No description
1229 name: vim2
1230 schema_version: '1.1'
1231 vim_password: 5g0yGX86qIhprX86YTMcpg==
1232 vim_tenant_name: osm
1233 vim_type: dumy
1234 vim_url: http://10.95.88.162:5000/v2.0
1235 vim_user: osm
1236 """
1237
1238 db_k8sclusters_text = """
1239 - _admin:
1240 created: 1575031378.9268339
1241 current_operation: 0
1242 modified: 1575031378.9268339
1243 operationalState: ENABLED
1244 operations:
1245 - detailed-status: ''
1246 lcmOperationType: create
1247 operationParams: null
1248 operationState: ''
1249 startTime: 1575031378.926895
1250 statusEnteredTime: 1575031378.926895
1251 worker: 36681ccf7f32
1252 projects_read:
1253 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
1254 projects_write:
1255 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
1256 helm-chart:
1257 id: 73d96432-d692-40d2-8440-e0c73aee209c
1258 created: True
1259 _id: e7169dab-f71a-4f1f-b82b-432605e8c4b3
1260 credentials:
1261 apiVersion: v1
1262 users:
1263 - name: admin
1264 user:
1265 password: qhpdogJXhBLG+JiYyyE0LeNsJXHkCSMy+sGVzlnJqes=
1266 username: admin
1267 description: Cluster3
1268 k8s_version: '1.15'
1269 name: cluster3
1270 namespace: kube-system
1271 nets:
1272 net1: None
1273 schema_version: '1.11'
1274 vim_account: ea958ba5-4e58-4405-bf42-6e3be15d4c3a
1275 """
1276
1277 db_vnfds_text = """
1278 ---
1279 - _admin:
1280 created: 1566823352.7154346
1281 modified: 1566823353.9295402
1282 onboardingState: ONBOARDED
1283 operationalState: ENABLED
1284 projects_read:
1285 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
1286 projects_write:
1287 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
1288 storage:
1289 descriptor: hackfest_3charmed_vnfd/hackfest_3charmed_vnfd.yaml
1290 folder: 7637bcf8-cf14-42dc-ad70-c66fcf1e6e77
1291 fs: local
1292 path: /app/storage/
1293 pkg-dir: hackfest_3charmed_vnfd
1294 zipfile: package.tar.gz
1295 type: vnfd
1296 usageState: NOT_IN_USE
1297 userDefinedData: {}
1298 _id: 7637bcf8-cf14-42dc-ad70-c66fcf1e6e77
1299 connection-point:
1300 - id: vnf-mgmt
1301 name: vnf-mgmt
1302 short-name: vnf-mgmt
1303 type: VPORT
1304 - id: vnf-data
1305 name: vnf-data
1306 short-name: vnf-data
1307 type: VPORT
1308 description: A VNF consisting of 2 VDUs connected to an internal VL, and one VDU
1309 with cloud-init
1310 id: hackfest3charmed-vnf
1311 internal-vld:
1312 - id: internal
1313 internal-connection-point:
1314 - id-ref: mgmtVM-internal
1315 - id-ref: dataVM-internal
1316 name: internal
1317 short-name: internal
1318 type: ELAN
1319 logo: osm.png
1320 mgmt-interface:
1321 cp: vnf-mgmt
1322 monitoring-param:
1323 - aggregation-type: AVERAGE
1324 id: monitor1
1325 name: monitor1
1326 vdu-monitoring-param:
1327 vdu-monitoring-param-ref: dataVM_cpu_util
1328 vdu-ref: dataVM
1329 name: hackfest3charmed-vnf
1330 scaling-group-descriptor:
1331 - max-instance-count: 10
1332 name: scale_dataVM
1333 scaling-config-action:
1334 - trigger: post-scale-out
1335 vnf-config-primitive-name-ref: touch
1336 - trigger: pre-scale-in
1337 vnf-config-primitive-name-ref: touch
1338 scaling-policy:
1339 - cooldown-time: 60
1340 name: auto_cpu_util_above_threshold
1341 scaling-criteria:
1342 - name: cpu_util_above_threshold
1343 scale-in-relational-operation: LE
1344 scale-in-threshold: '15.0000000000'
1345 scale-out-relational-operation: GE
1346 scale-out-threshold: '60.0000000000'
1347 vnf-monitoring-param-ref: monitor1
1348 scaling-type: automatic
1349 threshold-time: 0
1350 vdu:
1351 - count: 1
1352 vdu-id-ref: dataVM
1353 short-name: hackfest3charmed-vnf
1354 vdu:
1355 - count: '1'
1356 cloud-init-file: cloud-config.txt
1357 id: mgmtVM
1358 image: hackfest3-mgmt
1359 interface:
1360 - external-connection-point-ref: vnf-mgmt
1361 name: mgmtVM-eth0
1362 position: 1
1363 type: EXTERNAL
1364 virtual-interface:
1365 type: VIRTIO
1366 - internal-connection-point-ref: mgmtVM-internal
1367 name: mgmtVM-eth1
1368 position: 2
1369 type: INTERNAL
1370 virtual-interface:
1371 type: VIRTIO
1372 internal-connection-point:
1373 - id: mgmtVM-internal
1374 name: mgmtVM-internal
1375 short-name: mgmtVM-internal
1376 type: VPORT
1377 name: mgmtVM
1378 vm-flavor:
1379 memory-mb: '1024'
1380 storage-gb: '10'
1381 vcpu-count: 1
1382 - count: '1'
1383 id: dataVM
1384 image: hackfest3-mgmt
1385 interface:
1386 - internal-connection-point-ref: dataVM-internal
1387 name: dataVM-eth0
1388 position: 1
1389 type: INTERNAL
1390 virtual-interface:
1391 type: VIRTIO
1392 - external-connection-point-ref: vnf-data
1393 name: dataVM-xe0
1394 position: 2
1395 type: EXTERNAL
1396 virtual-interface:
1397 type: VIRTIO
1398 internal-connection-point:
1399 - id: dataVM-internal
1400 name: dataVM-internal
1401 short-name: dataVM-internal
1402 type: VPORT
1403 monitoring-param:
1404 - id: dataVM_cpu_util
1405 nfvi-metric: cpu_utilization
1406 name: dataVM
1407 vm-flavor:
1408 memory-mb: '1024'
1409 storage-gb: '10'
1410 vcpu-count: 1
1411 version: '1.0'
1412 vnf-configuration:
1413 config-access:
1414 ssh-access:
1415 required: True
1416 default-user: ubuntu
1417 config-primitive:
1418 - name: touch
1419 parameter:
1420 - data-type: STRING
1421 default-value: <touch_filename2>
1422 name: filename
1423 initial-config-primitive:
1424 - name: config
1425 parameter:
1426 - name: ssh-hostname
1427 value: <rw_mgmt_ip>
1428 - name: ssh-username
1429 value: ubuntu
1430 - name: ssh-password
1431 value: osm4u
1432 seq: '1'
1433 - name: touch
1434 parameter:
1435 - name: filename
1436 value: <touch_filename>
1437 seq: '2'
1438 juju:
1439 charm: simple
1440 - _admin:
1441 created: 1575031727.5383403
1442 modified: 1575031727.5383403
1443 onboardingState: ONBOARDED
1444 operationalState: ENABLED
1445 projects_read:
1446 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
1447 projects_write:
1448 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
1449 storage:
1450 descriptor: multikdu_knf/multikdu_vnfd.yaml
1451 folder: 7ab0d10d-8ce2-4c68-aef6-cc5a437a9c62
1452 fs: local
1453 path: /app/storage/
1454 pkg-dir: multikdu_knf
1455 zipfile: multikdu_knf.tar.gz
1456 usageState: NOT_IN_USE
1457 userDefinedData: {}
1458 _id: 7ab0d10d-8ce2-4c68-aef6-cc5a437a9c62
1459 connection-point:
1460 - name: mgmt
1461 description: KNF with two KDU using helm-charts
1462 id: multikdu_knf
1463 k8s-cluster:
1464 nets:
1465 - external-connection-point-ref: mgmt
1466 id: mgmtnet
1467 kdu:
1468 - helm-chart: stable/openldap:1.2.1
1469 name: ldap
1470 - helm-chart: stable/mongodb
1471 name: mongo
1472 mgmt-interface:
1473 cp: mgmt
1474 name: multikdu_knf
1475 short-name: multikdu_knf
1476 vendor: Telefonica
1477 version: '1.0'
1478 """
1479
1480 db_vnfrs_text = """
1481 ---
1482 - _admin:
1483 created: 1566823354.3668208
1484 modified: 1566823354.3668208
1485 nsState: NOT_INSTANTIATED
1486 projects_read:
1487 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
1488 projects_write:
1489 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
1490 _id: 88d90b0c-faff-4b9f-bccd-017f33985984
1491 additionalParamsForVnf:
1492 touch_filename: /home/ubuntu/first-touch-1
1493 touch_filename2: /home/ubuntu/second-touch-1
1494 connection-point:
1495 - connection-point-id: vnf-mgmt
1496 id: vnf-mgmt
1497 name: vnf-mgmt
1498 - connection-point-id: vnf-data
1499 id: vnf-data
1500 name: vnf-data
1501 created-time: 1566823354.36234
1502 id: 88d90b0c-faff-4b9f-bccd-017f33985984
1503 ip-address: 10.205.1.46
1504 member-vnf-index-ref: '1'
1505 nsr-id-ref: f48163a6-c807-47bc-9682-f72caef5af85
1506 vdur:
1507 - _id: f0e7d7ce-2443-4dcb-ad0b-5ab9f3b13d37
1508 count-index: 0
1509 interfaces:
1510 - ip-address: 10.205.1.46
1511 mac-address: fa:16:3e:b4:3e:b1
1512 mgmt-vnf: true
1513 name: mgmtVM-eth0
1514 ns-vld-id: mgmt
1515 - ip-address: 192.168.54.2
1516 mac-address: fa:16:3e:6e:7e:78
1517 name: mgmtVM-eth1
1518 vnf-vld-id: internal
1519 internal-connection-point:
1520 - connection-point-id: mgmtVM-internal
1521 id: mgmtVM-internal
1522 name: mgmtVM-internal
1523 ip-address: 10.205.1.46
1524 name: ALF-1-mgmtVM-1
1525 status: ACTIVE
1526 status-detailed: null
1527 vdu-id-ref: mgmtVM
1528 vim-id: c2538499-4c30-41c0-acd5-80cb92f48061
1529 - _id: ab453219-2d9a-45c2-864d-2c0788385028
1530 count-index: 0
1531 interfaces:
1532 - ip-address: 192.168.54.3
1533 mac-address: fa:16:3e:d9:7a:5d
1534 name: dataVM-eth0
1535 vnf-vld-id: internal
1536 - ip-address: 192.168.24.3
1537 mac-address: fa:16:3e:d1:6c:0d
1538 name: dataVM-xe0
1539 ns-vld-id: datanet
1540 internal-connection-point:
1541 - connection-point-id: dataVM-internal
1542 id: dataVM-internal
1543 name: dataVM-internal
1544 ip-address: null
1545 name: ALF-1-dataVM-1
1546 status: ACTIVE
1547 status-detailed: null
1548 vdu-id-ref: dataVM
1549 vim-id: 87973c3f-365d-4227-95c2-7a8abc74349c
1550 vim-account-id: ea958ba5-4e58-4405-bf42-6e3be15d4c3a
1551 vld:
1552 - id: internal
1553 name: ALF-internal
1554 status: ACTIVE
1555 status-detailed: null
1556 vim-id: ff181e6d-2597-4244-b40b-bb0174bdfeb6
1557 vnfd-id: 7637bcf8-cf14-42dc-ad70-c66fcf1e6e77
1558 vnfd-ref: hackfest3charmed-vnf
1559 - _admin:
1560 created: 1566823354.3703845
1561 modified: 1566823354.3703845
1562 nsState: NOT_INSTANTIATED
1563 projects_read:
1564 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
1565 projects_write:
1566 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
1567 _id: 1ca3bb1a-b29b-49fe-bed6-5f3076d77434
1568 additionalParamsForVnf:
1569 touch_filename: /home/ubuntu/first-touch-2
1570 touch_filename2: /home/ubuntu/second-touch-2
1571 connection-point:
1572 - connection-point-id: vnf-mgmt
1573 id: vnf-mgmt
1574 name: vnf-mgmt
1575 - connection-point-id: vnf-data
1576 id: vnf-data
1577 name: vnf-data
1578 created-time: 1566823354.36234
1579 id: 1ca3bb1a-b29b-49fe-bed6-5f3076d77434
1580 ip-address: 10.205.1.47
1581 member-vnf-index-ref: '2'
1582 nsr-id-ref: f48163a6-c807-47bc-9682-f72caef5af85
1583 vdur:
1584 - _id: 190b4a2c-4f85-4cfe-9406-4cef7ffb1e67
1585 count-index: 0
1586 interfaces:
1587 - ip-address: 10.205.1.47
1588 mac-address: fa:16:3e:cb:9f:c7
1589 mgmt-vnf: true
1590 name: mgmtVM-eth0
1591 ns-vld-id: mgmt
1592 - ip-address: 192.168.231.1
1593 mac-address: fa:16:3e:1a:89:24
1594 name: mgmtVM-eth1
1595 vnf-vld-id: internal
1596 internal-connection-point:
1597 - connection-point-id: mgmtVM-internal
1598 id: mgmtVM-internal
1599 name: mgmtVM-internal
1600 ip-address: 10.205.1.47
1601 name: ALF-2-mgmtVM-1
1602 status: ACTIVE
1603 status-detailed: null
1604 vdu-id-ref: mgmtVM
1605 vim-id: 248077b2-e3b8-4a37-8b72-575abb8ed912
1606 - _id: 889b874d-e1c3-4e75-aa45-53a9b0ddabd9
1607 count-index: 0
1608 interfaces:
1609 - ip-address: 192.168.231.3
1610 mac-address: fa:16:3e:7e:ba:8c
1611 name: dataVM-eth0
1612 vnf-vld-id: internal
1613 - ip-address: 192.168.24.4
1614 mac-address: fa:16:3e:d2:e1:f5
1615 name: dataVM-xe0
1616 ns-vld-id: datanet
1617 internal-connection-point:
1618 - connection-point-id: dataVM-internal
1619 id: dataVM-internal
1620 name: dataVM-internal
1621 ip-address: null
1622 name: ALF-2-dataVM-1
1623 status: ACTIVE
1624 status-detailed: null
1625 vdu-id-ref: dataVM
1626 vim-id: a4ce4372-e0ad-4ae3-8f9f-1c969f32e77b
1627 vim-account-id: ea958ba5-4e58-4405-bf42-6e3be15d4c3a
1628 vld:
1629 - id: internal
1630 name: ALF-internal
1631 status: ACTIVE
1632 status-detailed: null
1633 vim-id: ff181e6d-2597-4244-b40b-bb0174bdfeb6
1634 vnfd-id: 7637bcf8-cf14-42dc-ad70-c66fcf1e6e77
1635 vnfd-ref: hackfest3charmed-vnf
1636 - _admin:
1637 created: 1575034637.009597
1638 modified: 1575034637.009597
1639 nsState: NOT_INSTANTIATED
1640 projects_read:
1641 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
1642 projects_write:
1643 - 25b5aebf-3da1-49ed-99de-1d2b4a86d6e4
1644 _id: 5ac34899-a23a-4b3c-918a-cd77acadbea6
1645 additionalParamsForVnf: null
1646 connection-point:
1647 - connection-point-id: null
1648 id: null
1649 name: mgmt
1650 created-time: 1575034636.9990137
1651 id: 5ac34899-a23a-4b3c-918a-cd77acadbea6
1652 ip-address: null
1653 k8s-cluster:
1654 nets:
1655 - external-connection-point-ref: mgmt
1656 id: mgmtnet
1657 ns-vld-id: mgmtnet
1658 vim_net: internal
1659 kdur:
1660 - ip-address: null
1661 k8s-cluster:
1662 id: e7169dab-f71a-4f1f-b82b-432605e8c4b3
1663 kdu-name: ldap
1664 helm-chart: stable/openldap:1.2.1
1665 - ip-address: null
1666 k8s-cluster:
1667 id: e7169dab-f71a-4f1f-b82b-432605e8c4b3
1668 kdu-name: mongo
1669 helm-chart: stable/mongodb
1670 member-vnf-index-ref: multikdu
1671 nsr-id-ref: 0bcb701c-ee4d-41ab-8ee6-f4156f7f114d
1672 vdur: []
1673 vim-account-id: 74337dcb-ef54-41e7-bd2d-8c0d7fcd326f
1674 vnfd-id: 7ab0d10d-8ce2-4c68-aef6-cc5a437a9c62
1675 vnfd-ref: multikdu_knf
1676 """
1677
1678 db_nslcmops_scale_text = """
1679 ---
1680 - _admin:
1681 created: 1565250912.2643092
1682 modified: 1570026174.83263
1683 projects_read:
1684 - d3581c99-31e3-45f9-b45c-49a290faedbc
1685 current_operation: '5'
1686 deployed:
1687 RO: d9aea288-b9b1-11e9-b19e-02420aff0006
1688 RO-account: d9bb2f1c-b9b1-11e9-b19e-02420aff0006
1689 detailed-status: Done
1690 modified: 1565250912.2643092
1691 operationalState: ENABLED
1692 operations:
1693 - member_vnf_index: '1'
1694 primitive: touch
1695 primitive_params: /home/ubuntu/last-touch-1
1696 operationState: COMPLETED
1697 detailed-status: Done
1698 - member_vnf_index: '1'
1699 primitive: touch
1700 primitive_params: /home/ubuntu/last-touch-2
1701 operationState: COMPLETED
1702 detailed-status: Done
1703 - member_vnf_index: '2'
1704 primitive: touch
1705 primitive_params: /home/ubuntu/last-touch-3
1706 operationState: COMPLETED
1707 detailed-status: Done
1708 projects_read:
1709 - b2d2ce4b-a1a0-4c01-847e-048632c43b40
1710 projects_write:
1711 - b2d2ce4b-a1a0-4c01-847e-048632c43b40
1712 worker: c4055a07655b
1713 deploy:
1714 RO: ACTION-1570026232.061742
1715 _id: 053967e8-7c1c-400f-ae82-3d45b291374b
1716 lcmOperationType: scale
1717 nsInstanceId: 90d9ebb7-2b5a-4b7c-bc34-a51fd7ef7b7b
1718 statusEnteredTime: 1570026243.09784
1719 startTime: 1570026174.8326
1720 operationParams:
1721 lcmOperationType: scale
1722 nsInstanceId: 90d9ebb7-2b5a-4b7c-bc34-a51fd7ef7b7b
1723 scaleVnfData:
1724 scaleByStepData:
1725 member-vnf-index: '1'
1726 scaling-group-descriptor: scale_scaling_group
1727 scaleVnfType: SCALE_IN
1728 scaleType: SCALE_VNF
1729 isAutomaticInvocation: false
1730 isCancelPending: false
1731 id: 053967e8-7c1c-400f-ae82-3d45b291374b
1732 links:
1733 nsInstance: "/osm/nslcm/v1/ns_instances/90d9ebb7-2b5a-4b7c-bc34-a51fd7ef7b7b"
1734 self: "/osm/nslcm/v1/ns_lcm_op_occs/053967e8-7c1c-400f-ae82-3d45b291374b"
1735 operationState: COMPLETED
1736 detailed-status: done
1737 """
1738
1739 test_ids = {
1740 # contains the ids of ns and operations of every test
1741 "TEST-A": {
1742 "ns": "f48163a6-c807-47bc-9682-f72caef5af85",
1743 "instantiate": "a639fac7-e0bb-4225-8ecb-c1f8efcc125e",
1744 "terminate": "a639fac7-e0bb-4225-ffff-c1f8efcc125e",
1745 },
1746 "TEST-KDU": {
1747 "ns": "0bcb701c-ee4d-41ab-8ee6-f4156f7f114d",
1748 "instantiate": "cf3aa178-7640-4174-b921-2330e6f2aad6",
1749 "terminate": None,
1750 }
1751 }