summaryrefslogtreecommitdiffstats
path: root/catalog-be/src/main/resources/scripts
diff options
context:
space:
mode:
authordavsad <david.sadlier@est.tech>2021-08-24 12:06:51 +0100
committerDavid Sadlier <david.sadlier@est.tech>2021-08-26 14:30:06 +0000
commit69cb5577bc59f8b25b0b267f5ea5e37c6aa20dbd (patch)
treeaee206db8c05ed98e01a989438e935421cf070f4 /catalog-be/src/main/resources/scripts
parentbc741a1eeb2455903734a5603281cc17ca898d11 (diff)
Add ETSI SOL001 v2.5.1 model types to backend init
Issue-ID: SDC-3685 Change-Id: I59e56cbe071c21467d0f683c7c977a8ceca6e221 Signed-off-by: davsad <david.sadlier@est.tech>
Diffstat (limited to 'catalog-be/src/main/resources/scripts')
-rw-r--r--catalog-be/src/main/resources/scripts/sdcBePy/tosca/imports/run.py9
1 files changed, 3 insertions, 6 deletions
diff --git a/catalog-be/src/main/resources/scripts/sdcBePy/tosca/imports/run.py b/catalog-be/src/main/resources/scripts/sdcBePy/tosca/imports/run.py
index 1df54ca50e..41437707aa 100644
--- a/catalog-be/src/main/resources/scripts/sdcBePy/tosca/imports/run.py
+++ b/catalog-be/src/main/resources/scripts/sdcBePy/tosca/imports/run.py
@@ -20,15 +20,12 @@ def main(sdc_be_proxy, update_version):
if sdc_be_proxy.disable_locking("true") != 200:
raise RuntimeError("Failed to disable locking")
try:
- model_import_manager = ModelImportManager(Path(base_file_location) / 'models', ModelClient(sdc_be_proxy))
- try:
- model_import_manager.create_models()
- except Exception as ex:
- logger.log("An error has occurred while uploading the models: ", str(ex))
- raise ex
process_element_list(normativeElementsList.get_normative_element_candidate_list(base_file_location), sdc_be_proxy)
process_type_list(normativeTypesList.get_normative_type_candidate_list(base_file_location), sdc_be_proxy, update_version)
process_element_list(normativeElementsList.get_normative_element_with_metadata_list(base_file_location), sdc_be_proxy)
+ #Add model based normatives
+ model_import_manager = ModelImportManager(Path(base_file_location) / 'models', ModelClient(sdc_be_proxy))
+ model_import_manager.create_models()
except Exception as ex:
logger.log("An error has occurred while uploading elements and types: ", str(ex))
raise ex