summaryrefslogtreecommitdiffstats
path: root/adapters
diff options
context:
space:
mode:
authorKuleshov, Elena <evn@att.com>2020-04-07 15:50:32 -0400
committerBenjamin, Max (mb388a) <mb388a@att.com>2020-04-07 15:50:34 -0400
commit654db79e01a20632cf1d7c3c6a786160aaa82eed (patch)
tree5098ed345998eee759fa2b193ebaac47b48bf795 /adapters
parentda123b489a80779f3162d9e007616c6a083414bc (diff)
Add workflowName and operationName to v8 of
Add workflowName and operationName to v8 of orchestrationRequests response. Fix typo in the schema for infra_active_requests. Change version matching for the new interface fields. Issue-ID: SO-2799 Signed-off-by: Benjamin, Max (mb388a) <mb388a@att.com> Change-Id: Icc7f3c6271023a578df2c1d969c807a578cc9577
Diffstat (limited to 'adapters')
-rw-r--r--adapters/mso-requests-db-adapter/src/main/java/org/onap/so/adapters/requestsdb/ArchiveInfraRequestsScheduler.java2
-rw-r--r--adapters/mso-requests-db-adapter/src/main/resources/db/migration/V8.3__Add_Columns_Workflow_Name_Operation_Name.sql7
2 files changed, 9 insertions, 0 deletions
diff --git a/adapters/mso-requests-db-adapter/src/main/java/org/onap/so/adapters/requestsdb/ArchiveInfraRequestsScheduler.java b/adapters/mso-requests-db-adapter/src/main/java/org/onap/so/adapters/requestsdb/ArchiveInfraRequestsScheduler.java
index 9f48144eb8..4fe49e38dd 100644
--- a/adapters/mso-requests-db-adapter/src/main/java/org/onap/so/adapters/requestsdb/ArchiveInfraRequestsScheduler.java
+++ b/adapters/mso-requests-db-adapter/src/main/java/org/onap/so/adapters/requestsdb/ArchiveInfraRequestsScheduler.java
@@ -143,6 +143,8 @@ public class ArchiveInfraRequestsScheduler {
archivedInfra.setProductFamilyName(iar.getProductFamilyName());
archivedInfra.setTenantName(iar.getTenantName());
archivedInfra.setResourceStatusMessage(iar.getResourceStatusMessage());
+ archivedInfra.setWorkflowName(iar.getWorkflowName());
+ archivedInfra.setOperationName(iar.getOperationName());
newArchivedReqs.add(archivedInfra);
oldInfraReqs.add(iar);
diff --git a/adapters/mso-requests-db-adapter/src/main/resources/db/migration/V8.3__Add_Columns_Workflow_Name_Operation_Name.sql b/adapters/mso-requests-db-adapter/src/main/resources/db/migration/V8.3__Add_Columns_Workflow_Name_Operation_Name.sql
new file mode 100644
index 0000000000..d493bc01ac
--- /dev/null
+++ b/adapters/mso-requests-db-adapter/src/main/resources/db/migration/V8.3__Add_Columns_Workflow_Name_Operation_Name.sql
@@ -0,0 +1,7 @@
+use requestdb;
+
+ALTER TABLE infra_active_requests ADD COLUMN IF NOT EXISTS WORKFLOW_NAME varchar(200);
+ALTER TABLE archived_infra_requests ADD COLUMN IF NOT EXISTS WORKFLOW_NAME varchar(200);
+
+ALTER TABLE infra_active_requests ADD COLUMN IF NOT EXISTS OPERATION_NAME varchar(200);
+ALTER TABLE archived_infra_requests ADD COLUMN IF NOT EXISTS OPERATION_NAME varchar(200); \ No newline at end of file