summaryrefslogtreecommitdiffstats
path: root/ms/blueprintsprocessor/functions/restconf-executor/src
diff options
context:
space:
mode:
Diffstat (limited to 'ms/blueprintsprocessor/functions/restconf-executor/src')
-rw-r--r--ms/blueprintsprocessor/functions/restconf-executor/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/restconf/executor/RestconfComponentFunction.kt13
1 files changed, 7 insertions, 6 deletions
diff --git a/ms/blueprintsprocessor/functions/restconf-executor/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/restconf/executor/RestconfComponentFunction.kt b/ms/blueprintsprocessor/functions/restconf-executor/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/restconf/executor/RestconfComponentFunction.kt
index b95879274..3895c39c8 100644
--- a/ms/blueprintsprocessor/functions/restconf-executor/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/restconf/executor/RestconfComponentFunction.kt
+++ b/ms/blueprintsprocessor/functions/restconf-executor/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/restconf/executor/RestconfComponentFunction.kt
@@ -17,6 +17,7 @@
package org.onap.ccsdk.cds.blueprintsprocessor.functions.restconf.executor
+import kotlinx.coroutines.runBlocking
import org.onap.ccsdk.cds.blueprintsprocessor.functions.resource.resolution.ResourceResolutionConstants
import org.onap.ccsdk.cds.blueprintsprocessor.functions.resource.resolution.ResourceResolutionService
import org.onap.ccsdk.cds.blueprintsprocessor.rest.RestLibConstants
@@ -38,21 +39,21 @@ abstract class RestconfComponentFunction : AbstractScriptComponentFunction() {
return bluePrintRestLibPropertyService().blueprintWebClientService(selector)
}
- fun resolveFromDatabase(resolutionKey: String, artifactName: String): String {
- return resourceResolutionService().resolveFromDatabase(bluePrintRuntimeService, artifactName, resolutionKey)
+ fun resolveFromDatabase(resolutionKey: String, artifactName: String): String = runBlocking {
+ resourceResolutionService().resolveFromDatabase(bluePrintRuntimeService, artifactName, resolutionKey)
}
fun generateMessage(artifactName: String): String {
return bluePrintRuntimeService.resolveNodeTemplateArtifact(nodeTemplateName, artifactName)
}
- fun resolveAndGenerateMessage(artifactMapping: String, artifactTemplate: String): String {
- return resourceResolutionService().resolveResources(bluePrintRuntimeService, nodeTemplateName,
+ fun resolveAndGenerateMessage(artifactMapping: String, artifactTemplate: String): String = runBlocking {
+ resourceResolutionService().resolveResources(bluePrintRuntimeService, nodeTemplateName,
artifactMapping, artifactTemplate)
}
- fun resolveAndGenerateMessage(artifactPrefix: String): String {
- return resourceResolutionService().resolveResources(bluePrintRuntimeService, nodeTemplateName,
+ fun resolveAndGenerateMessage(artifactPrefix: String): String = runBlocking {
+ resourceResolutionService().resolveResources(bluePrintRuntimeService, nodeTemplateName,
artifactPrefix, mapOf())
}
} \ No newline at end of file