summaryrefslogtreecommitdiffstats
path: root/ms/blueprintsprocessor/modules/inbounds/selfservice-api/src
diff options
context:
space:
mode:
authorBrinda Santh <brindasanth@in.ibm.com>2019-07-31 15:49:27 -0400
committerBrinda Santh Muthuramalingam <brindasanth@in.ibm.com>2019-07-31 22:23:14 +0000
commitdd710215139505f26f052a7dbdcdb5bf7f2e0532 (patch)
tree9238c43fbd0539194b5c4f4f818dae06ec405431 /ms/blueprintsprocessor/modules/inbounds/selfservice-api/src
parent82a22313f1d87f32417c5a878ffb7e20cfd464fe (diff)
Fix compiler cache to hold for next transaction.
Change-Id: Ibede4a378980717d49708f7665ab295534a092a0 Issue-ID: CCSDK-1046 Signed-off-by: Brinda Santh <brindasanth@in.ibm.com>
Diffstat (limited to 'ms/blueprintsprocessor/modules/inbounds/selfservice-api/src')
-rw-r--r--ms/blueprintsprocessor/modules/inbounds/selfservice-api/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/selfservice/api/ExecutionServiceHandler.kt6
1 files changed, 6 insertions, 0 deletions
diff --git a/ms/blueprintsprocessor/modules/inbounds/selfservice-api/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/selfservice/api/ExecutionServiceHandler.kt b/ms/blueprintsprocessor/modules/inbounds/selfservice-api/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/selfservice/api/ExecutionServiceHandler.kt
index 094fb68da..a81d35eac 100644
--- a/ms/blueprintsprocessor/modules/inbounds/selfservice-api/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/selfservice/api/ExecutionServiceHandler.kt
+++ b/ms/blueprintsprocessor/modules/inbounds/selfservice-api/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/selfservice/api/ExecutionServiceHandler.kt
@@ -30,6 +30,8 @@ import org.onap.ccsdk.cds.controllerblueprints.core.config.BluePrintPathConfigur
import org.onap.ccsdk.cds.controllerblueprints.core.data.ErrorCode
import org.onap.ccsdk.cds.controllerblueprints.core.interfaces.BluePrintCatalogService
import org.onap.ccsdk.cds.controllerblueprints.core.interfaces.BluePrintWorkflowExecutionService
+import org.onap.ccsdk.cds.controllerblueprints.core.scripts.BluePrintCompileCache
+import org.onap.ccsdk.cds.controllerblueprints.core.utils.BluePrintFileUtils
import org.onap.ccsdk.cds.controllerblueprints.core.utils.BluePrintMetadataUtils
import org.slf4j.LoggerFactory
import org.springframework.http.codec.multipart.FilePart
@@ -63,6 +65,10 @@ class ExecutionServiceHandler(private val bluePrintPathConfiguration: BluePrintP
throw BluePrintException(ErrorCode.IO_FILE_INTERRUPT.value,
"Error in Upload CBA: ${e.message}", e)
} finally {
+ // Clean blueprint script cache
+ val cacheKey = BluePrintFileUtils
+ .compileCacheKey(normalizedPathName(bluePrintPathConfiguration.blueprintWorkingPath,saveId))
+ BluePrintCompileCache.cleanClassLoader(cacheKey)
deleteNBDir(blueprintArchive)
deleteNBDir(blueprintWorking)
}