OSMENG-1048 Implement day1 configuration for VDU (improved) 53/13353/7
authorGulsum Atici <gulsum.atici@canonical.com>
Fri, 5 May 2023 06:44:22 +0000 (09:44 +0300)
committerGulsum Atici <gulsum.atici@canonical.com>
Wed, 31 May 2023 08:49:04 +0000 (11:49 +0300)
Change-Id: Ic22bb5b1f043c1a0edefc3b281e9722a27d2a24b
Signed-off-by: Gulsum Atici <gulsum.atici@canonical.com>
osm_common/dataclasses/temporal_dataclasses.py
osm_common/temporal_constants.py

index de541f2..5827ab8 100644 (file)
@@ -207,6 +207,48 @@ class VnfInstantiateInput:
 
     model_name: str
 
+    instantiation_config: dict
+        The instantiation configuration of the VNF
+
+    """
+
+    vnfr_uuid: str
+    model_name: str
+    instantiation_config: dict
+
+
+@dataclass
+class SetVnfModelInput:
+    """
+    Input dataclass for activity that sets the VNF Model.
+
+    Attributes:
+    -----------
+    vnfr_uuid : str
+        The UUID of the VNF which is stored in the OSM vnfrs
+        collection in Mongo.
+
+    model_name: str
+
+    """
+
+    vnfr_uuid: str
+    model_name: str
+
+
+@dataclass
+class VnfPrepareInput:
+    """
+    Input dataclass for workflow that prepare a VNF.
+
+    Attributes:
+    -----------
+    vnfr_uuid : str
+        The UUID of the VNF which is stored in the OSM vnfrs
+        collection in Mongo.
+
+    model_name: str
+
     """
 
     vnfr_uuid: str
@@ -534,7 +576,7 @@ class GetTaskQueueOutput:
 
 
 @dataclass
-class GetVnfDetailsInput:
+class GetVnfRecordInput:
     """
     Input dataclass for get vnf details activity.
 
@@ -549,7 +591,7 @@ class GetVnfDetailsInput:
 
 
 @dataclass
-class GetVnfDetailsOutput:
+class GetVnfRecordOutput:
     """
     Output dataclass for get vnf details activity.
 
@@ -558,16 +600,42 @@ class GetVnfDetailsOutput:
     vnfr : dict
         VNF record retrieved from Database.
 
+    """
+
+    vnfr: dict
+
+
+@dataclass
+class GetVnfDescriptorInput:
+    """
+    Input dataclass for get vnf details activity.
+
+    Attributes:
+    -----------
+    vnfd_uuid : str
+        The UUID of the VNF descriptor which is stored in the OSM vnfds
+        collection in Mongo.
+    """
+
+    vnfd_uuid: str
+
+
+@dataclass
+class GetVnfDescriptorOutput:
+    """
+    Output dataclass for get vnf details activity.
+
+    Attributes:
+    -----------
     vnfd : dict
         VNF descriptor retrieved from Database.
     """
 
-    vnfr: dict
     vnfd: dict
 
 
 @dataclass
-class GetVnfRecordIdsInput:
+class GetVnfDetailsInput:
     """
     Attributes:
     -----------
@@ -579,12 +647,13 @@ class GetVnfRecordIdsInput:
 
 
 @dataclass
-class GetVnfRecordIdsOutput:
+class GetVnfDetailsOutput:
     """
     Attributes:
     -----------
-    vnfr_ids : list[str]
-        List of the VNF record IDs associated with the NS.
+    vnf_details: list[(vnfr_ids: str, vnf_member_index_ref: str), .. ]
+        List of tuples including VNF details associated with the NS.
+        Tuple(VNF record IDs, vnf_member_index_ref)
     """
 
-    vnfr_ids: List[str]
+    vnf_details: List[tuple]
index ca1bfc2..9a3af23 100644 (file)
@@ -31,7 +31,7 @@ ACTIVITY_TEST_VIM_CONNECTIVITY = "test-vim-connectivity"
 ACTIVITY_UPDATE_VIM_OPERATION_STATE = "update-vim-operation-state"
 ACTIVITY_UPDATE_VIM_STATE = "update-vim-state"
 ACTIVITY_GET_NS_RECORD = "get-ns-record"
-ACTIVITY_GET_VNF_RECORD_IDS = "get-vnf-record-ids"
+ACTIVITY_GET_VNF_DETAILS = "get-vnf-details"
 ACTIVITY_UPDATE_NS_STATE = "update-ns-state"
 ACTIVITY_CREATE_MODEL = "create-model"
 ACTIVITY_GET_MODEL_INFO = "get-model-info"
@@ -40,8 +40,9 @@ ACTIVITY_CHECK_CHARM_STATUS = "check-charm-status"
 ACTIVITY_CHANGE_VNF_STATE = "change-vnf-state"
 ACTIVITY_CHANGE_VNF_INSTANTIATION_STATE = "change-vnf-instantiation-state"
 ACTIVITY_SEND_NOTIFICATION_FOR_VNF = "send-notification-for-vnf"
-ACTIVITY_GET_TASK_QUEUE = "get_task_queue"
-ACTIVITY_GET_VNF_DETAILS = "get_vnf_details"
+ACTIVITY_GET_TASK_QUEUE = "get-task-queue"
+ACTIVITY_GET_VNF_RECORD = "get-vnf-record"
+ACTIVITY_GET_VNF_DESCRIPTOR = "get-vnf-descriptor"
 ACTIVITY_SET_VNF_MODEL = "set-vnf-model"
 ACTIVITY_GET_VIM_CLOUD = "get-vim-cloud"