summaryrefslogtreecommitdiffstats
path: root/bpmn/MSOCommonBPMN
diff options
context:
space:
mode:
Diffstat (limited to 'bpmn/MSOCommonBPMN')
-rw-r--r--bpmn/MSOCommonBPMN/src/main/groovy/org/openecomp/mso/bpmn/common/scripts/CatalogDbUtils.groovy21
1 files changed, 21 insertions, 0 deletions
diff --git a/bpmn/MSOCommonBPMN/src/main/groovy/org/openecomp/mso/bpmn/common/scripts/CatalogDbUtils.groovy b/bpmn/MSOCommonBPMN/src/main/groovy/org/openecomp/mso/bpmn/common/scripts/CatalogDbUtils.groovy
index dd6e56acc7..921e0ee00d 100644
--- a/bpmn/MSOCommonBPMN/src/main/groovy/org/openecomp/mso/bpmn/common/scripts/CatalogDbUtils.groovy
+++ b/bpmn/MSOCommonBPMN/src/main/groovy/org/openecomp/mso/bpmn/common/scripts/CatalogDbUtils.groovy
@@ -1203,4 +1203,25 @@ class CatalogDbUtils {
}
}
+
+ /**
+ * get resource recipe by resource model uuid and action
+ */
+ public JSONObject getResourceRecipe(Execution execution, String resourceModelUuid, String action) {
+ String endPoint = "/resourceRecipe?resourceModelUuid=" + UriUtils.encode(resourceModelUuid, "UTF-8")+ "&action=" + UriUtils.encode(action, "UTF-8")
+ JSONObject responseJson = null
+ try {
+ msoLogger.debug("ENDPOINT: " + endPoint)
+ String catalogDbResponse = getResponseFromCatalogDb(execution, endPoint)
+
+ if (catalogDbResponse != null) {
+ responseJson = new JSONObject(catalogDbResponse)
+ }
+ }
+ catch (Exception e) {
+ utils.log("ERROR", "Exception in Querying Catalog DB: " + e.message)
+ }
+
+ return responseJson
+ }
} \ No newline at end of file