Fix kotlin cache lazy loading 78/102878/9
authorSebastien Premont-Tendland <sebastien.premont@bell.ca>
Mon, 2 Mar 2020 19:33:33 +0000 (14:33 -0500)
committerSebastien Premont-Tendland <sebastien.premont@bell.ca>
Thu, 19 Mar 2020 13:28:18 +0000 (13:28 +0000)
commit0562fc1c7378be67b571bb142489272a6b1b3814
treebcf38c342cb21710725eb89c8b7cc25c91f13e66
parentfa12b4f311e77612e4e856b209a8c81c71f0b29d
Fix kotlin cache lazy loading

When USE_SCRIPT_COMPILATION_CACHE is set to false the classLoader
is closed after the class is instantiated. This is causing an issue
when lazy loading is happening during the script execution.

Lazy loading occurs when a suspendible function returning something
is called from "processNB", kotlin will create a second class that
will be loaded during execution (needs to be in the classpath during execution).

Issue-ID: CCSDK-2150

Signed-off-by: Sebastien Premont-Tendland <sebastien.premont@bell.ca>
Change-Id: I64780287352d762325662e0e5d5b94038dedee7f
ms/blueprintsprocessor/functions/netconf-executor/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/netconf/executor/ComponentNetconfExecutor.kt
ms/blueprintsprocessor/functions/resource-resolution/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/resource/resolution/processor/CapabilityResourceResolutionProcessor.kt
ms/blueprintsprocessor/functions/resource-resolution/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/resource/resolution/processor/CapabilityResourceResolutionProcessorTest.kt
ms/blueprintsprocessor/modules/blueprints/blueprint-core/src/main/kotlin/org/onap/ccsdk/cds/controllerblueprints/core/interfaces/BluePrintScriptsService.kt
ms/blueprintsprocessor/modules/blueprints/blueprint-core/src/main/kotlin/org/onap/ccsdk/cds/controllerblueprints/core/scripts/BluePrintCompileService.kt
ms/blueprintsprocessor/modules/blueprints/blueprint-core/src/main/kotlin/org/onap/ccsdk/cds/controllerblueprints/core/scripts/BluePrintScriptsServiceImpl.kt
ms/blueprintsprocessor/modules/services/execution-service/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/services/execution/ComponentFunctionScriptingService.kt
ms/blueprintsprocessor/modules/services/execution-service/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/services/execution/ComponentScriptExecutor.kt