Fix transition states for the BB workflow. 49/106549/2
authorSebastien Premont-Tendland <sebastien.premont@bell.ca>
Thu, 9 Apr 2020 14:07:56 +0000 (10:07 -0400)
committerSebastien Premont-Tendland <sebastien.premont@bell.ca>
Wed, 29 Apr 2020 19:27:24 +0000 (19:27 +0000)
Deleted the versioned flyway file in favor of the repeatable
one for MacroData. I know deleting a versioned file could mess up
upgrade but given no release has been done with those new versioned files
it should be ok and cleaner.

This is a list of transition states that were added internally at Bell
when working with the BB workflow and post instantiation.

Those are to support Rollback and Delete even if the VNF is in the status
ConfigAssigned, Configure or Configured.
The missing transition states was causing the Rollback or Delete to fail.

Issue-ID: SO-2798
Signed-off-by: Sebastien Premont-Tendland <sebastien.premont@bell.ca>
Change-Id: I21c11298a456a472cedc7a8733c6dbc3a071f3a6
(cherry picked from commit b1e92221cbed0131b0788e993ee224a42283a8a2)

adapters/mso-catalog-db-adapter/src/main/resources/db/migration/R__MacroData.sql
adapters/mso-catalog-db-adapter/src/main/resources/db/migration/V9.0__AddConfiguredForVnfOrchestrationStatus.sql [deleted file]

index b4366b3..e27ec2e 100644 (file)
@@ -624,7 +624,17 @@ VALUES
 
 ('VOLUME_GROUP', 'PENDING', 'DELETE', 'SILENT_SUCCESS'),
 ('VF_MODULE', 'PENDING', 'DELETE', 'FAIL'),
-('NETWORK', 'PENDING', 'DELETE', 'FAIL');
+('NETWORK', 'PENDING', 'DELETE', 'FAIL'),
+
+('VNF', 'CONFIGURED', 'ACTIVATE', 'CONTINUE'),
+('VNF', 'CONFIGURED', 'UNASSIGN', 'CONTINUE'),
+('VNF', 'CONFIGURED', 'DESACTIVATE', 'SILENT_SUCCESS'),
+
+('VNF', 'CONFIGURE', 'UNASSIGN', 'CONTINUE'),
+('VNF', 'CONFIGURE', 'DESACTIVATE', 'SILENT_SUCCESS'),
+
+('VNF', 'CONFIGASSIGNED', 'UNASSIGN', 'CONTINUE'),
+('VNF', 'CONFIGASSIGNED', 'DESACTIVATE', 'SILENT_SUCCESS');
 
 UPDATE orchestration_flow_reference SET FLOW_NAME = 'HomingBB' WHERE FLOW_NAME = 'SniroHoming';
 
diff --git a/adapters/mso-catalog-db-adapter/src/main/resources/db/migration/V9.0__AddConfiguredForVnfOrchestrationStatus.sql b/adapters/mso-catalog-db-adapter/src/main/resources/db/migration/V9.0__AddConfiguredForVnfOrchestrationStatus.sql
deleted file mode 100644 (file)
index 81e6092..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-INSERT INTO orchestration_status_state_transition_directive(RESOURCE_TYPE, ORCHESTRATION_STATUS, TARGET_ACTION, FLOW_DIRECTIVE)
-VALUES ('VNF', 'CONFIGURED', 'ACTIVATE', 'CONTINUE');