aboutsummaryrefslogtreecommitdiffstats
path: root/ms/blueprintsprocessor/functions/config-snapshots
diff options
context:
space:
mode:
authorJozsef Csongvai <jozsef.csongvai@bell.ca>2021-07-26 12:00:59 -0400
committerJozsef Csongvai <jozsef.csongvai@bell.ca>2021-07-28 15:44:01 -0400
commitdaab14bd058de198c80b71d63e108fd788b7f5ee (patch)
tree252cfdef5b2e1500e5bd152f3f5c52602b6b0deb /ms/blueprintsprocessor/functions/config-snapshots
parent82e396d6917519468376d177dd6a2710e84fa23a (diff)
Revert "Renaming Files having BluePrint to have Blueprint"
The renaming in CCSDK-3098 caused breaking changes to the grpc api and compile issues for kotlin scripts. Issue-ID: CCSDK-3385 Change-Id: I0d745cb858371678eabcb2284671c1fd76a1ab6d Signed-off-by: Jozsef Csongvai <jozsef.csongvai@bell.ca>
Diffstat (limited to 'ms/blueprintsprocessor/functions/config-snapshots')
-rw-r--r--ms/blueprintsprocessor/functions/config-snapshots/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/config/snapshots/db/ResourceConfigSnapshotService.kt4
-rw-r--r--ms/blueprintsprocessor/functions/config-snapshots/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/config/snapshots/ComponentConfigSnapshotsExecutorTest.kt28
-rw-r--r--ms/blueprintsprocessor/functions/config-snapshots/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/config/snapshots/TestDatabaseConfiguration.kt4
3 files changed, 18 insertions, 18 deletions
diff --git a/ms/blueprintsprocessor/functions/config-snapshots/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/config/snapshots/db/ResourceConfigSnapshotService.kt b/ms/blueprintsprocessor/functions/config-snapshots/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/config/snapshots/db/ResourceConfigSnapshotService.kt
index cf7de679b..7527f4a25 100644
--- a/ms/blueprintsprocessor/functions/config-snapshots/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/config/snapshots/db/ResourceConfigSnapshotService.kt
+++ b/ms/blueprintsprocessor/functions/config-snapshots/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/config/snapshots/db/ResourceConfigSnapshotService.kt
@@ -19,7 +19,7 @@ import kotlinx.coroutines.Dispatchers
import kotlinx.coroutines.withContext
import org.apache.logging.log4j.util.Strings
import org.onap.ccsdk.cds.blueprintsprocessor.functions.config.snapshots.db.ResourceConfigSnapshot.Status.RUNNING
-import org.onap.ccsdk.cds.controllerblueprints.core.BlueprintException
+import org.onap.ccsdk.cds.controllerblueprints.core.BluePrintException
import org.slf4j.LoggerFactory
import org.springframework.dao.DataIntegrityViolationException
import org.springframework.stereotype.Service
@@ -111,7 +111,7 @@ open class ResourceConfigSnapshotService(private val resourceConfigSnapshotRepos
"dated=(${storedSnapshot.createdDate})"
)
} catch (ex: DataIntegrityViolationException) {
- throw BlueprintException("Failed to store configuration snapshot entry.", ex)
+ throw BluePrintException("Failed to store configuration snapshot entry.", ex)
}
storedSnapshot
}
diff --git a/ms/blueprintsprocessor/functions/config-snapshots/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/config/snapshots/ComponentConfigSnapshotsExecutorTest.kt b/ms/blueprintsprocessor/functions/config-snapshots/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/config/snapshots/ComponentConfigSnapshotsExecutorTest.kt
index 99de66489..3a3dd102a 100644
--- a/ms/blueprintsprocessor/functions/config-snapshots/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/config/snapshots/ComponentConfigSnapshotsExecutorTest.kt
+++ b/ms/blueprintsprocessor/functions/config-snapshots/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/config/snapshots/ComponentConfigSnapshotsExecutorTest.kt
@@ -31,9 +31,9 @@ import org.onap.ccsdk.cds.blueprintsprocessor.functions.config.snapshots.Compone
import org.onap.ccsdk.cds.blueprintsprocessor.functions.config.snapshots.ComponentConfigSnapshotsExecutor.Companion.OPERATION_STORE
import org.onap.ccsdk.cds.blueprintsprocessor.functions.config.snapshots.db.ResourceConfigSnapshot
import org.onap.ccsdk.cds.blueprintsprocessor.functions.config.snapshots.db.ResourceConfigSnapshotService
-import org.onap.ccsdk.cds.controllerblueprints.core.BlueprintProcessorException
+import org.onap.ccsdk.cds.controllerblueprints.core.BluePrintProcessorException
import org.onap.ccsdk.cds.controllerblueprints.core.asJsonPrimitive
-import org.onap.ccsdk.cds.controllerblueprints.core.utils.BlueprintMetadataUtils
+import org.onap.ccsdk.cds.controllerblueprints.core.utils.BluePrintMetadataUtils
import org.onap.ccsdk.cds.controllerblueprints.core.utils.JacksonUtils
import org.springframework.beans.factory.annotation.Autowired
import org.springframework.context.annotation.ComponentScan
@@ -55,7 +55,7 @@ class ComponentConfigSnapshotsExecutorTest {
@Autowired
lateinit var cfgSnapshotService: ResourceConfigSnapshotService
lateinit var cfgSnapshotComponent: ComponentConfigSnapshotsExecutor
- private var bluePrintRuntimeService = BlueprintMetadataUtils.bluePrintRuntime(
+ private var bluePrintRuntimeService = BluePrintMetadataUtils.bluePrintRuntime(
"123456-1000",
"./../../../../components/model-catalog/blueprint-model/test-blueprint/remote_scripts"
)
@@ -99,7 +99,7 @@ class ComponentConfigSnapshotsExecutorTest {
prepareRequestProperties(OPERATION_FETCH, resId, resType, ResourceConfigSnapshot.Status.RUNNING.name)
cfgSnapshotComponent.processNB(executionRequest)
- } catch (e: BlueprintProcessorException) {
+ } catch (e: BluePrintProcessorException) {
kotlin.test.assertEquals(
"Can't proceed with the cfg snapshot lookup: provide resource-id and resource-type.",
e.message
@@ -138,7 +138,7 @@ class ComponentConfigSnapshotsExecutorTest {
prepareRequestProperties(OPERATION_FETCH, resId, resType, ResourceConfigSnapshot.Status.CANDIDATE.name)
cfgSnapshotComponent.processNB(executionRequest)
- } catch (e: BlueprintProcessorException) {
+ } catch (e: BluePrintProcessorException) {
kotlin.test.assertEquals(
"Can't proceed with the cfg snapshot lookup: provide resource-id and resource-type.",
e.message
@@ -176,7 +176,7 @@ class ComponentConfigSnapshotsExecutorTest {
prepareRequestProperties(OPERATION_STORE, resId, resType, snapshotConfig)
cfgSnapshotComponent.processNB(executionRequest)
- } catch (e: BlueprintProcessorException) {
+ } catch (e: BluePrintProcessorException) {
kotlin.test.assertEquals(
"Can't proceed with the cfg snapshot lookup: provide resource-id and resource-type.",
e.message
@@ -211,7 +211,7 @@ class ComponentConfigSnapshotsExecutorTest {
prepareRequestProperties(OPERATION_FETCH, "asdasd", "PNF", ResourceConfigSnapshot.Status.RUNNING.name)
cfgSnapshotComponent.processNB(executionRequest)
- } catch (e: BlueprintProcessorException) {
+ } catch (e: BluePrintProcessorException) {
kotlin.test.assertEquals(
"Can't proceed with the cfg snapshot lookup: provide resource-id and resource-type.",
e.message
@@ -238,7 +238,7 @@ class ComponentConfigSnapshotsExecutorTest {
prepareRequestProperties("update", "asdasd", "PNF", ResourceConfigSnapshot.Status.RUNNING.name)
cfgSnapshotComponent.processNB(executionRequest)
- } catch (e: BlueprintProcessorException) {
+ } catch (e: BluePrintProcessorException) {
kotlin.test.assertEquals(
"Can't proceed with the cfg snapshot lookup: provide resource-id and resource-type.",
e.message
@@ -247,7 +247,7 @@ class ComponentConfigSnapshotsExecutorTest {
}
// then; we should get error in our output properties
- assertTrue(bluePrintRuntimeService.getBlueprintError().allErrors().size == 1)
+ assertTrue(bluePrintRuntimeService.getBluePrintError().allErrors().size == 1)
assertEquals(
ComponentConfigSnapshotsExecutor.OUTPUT_STATUS_ERROR.asJsonPrimitive(),
bluePrintRuntimeService.getNodeTemplateAttributeValue(
@@ -278,7 +278,7 @@ class ComponentConfigSnapshotsExecutorTest {
prepareRequestProperties(OPERATION_DIFF, resId, resType, "YANG")
cfgSnapshotComponent.processNB(executionRequest)
- } catch (e: BlueprintProcessorException) {
+ } catch (e: BluePrintProcessorException) {
kotlin.test.assertEquals(
"Can't proceed with the cfg snapshot lookup: provide resource-id and resource-type.",
e.message
@@ -319,7 +319,7 @@ class ComponentConfigSnapshotsExecutorTest {
prepareRequestProperties(OPERATION_DIFF, resId, resType, DIFF_JSON)
cfgSnapshotComponent.processNB(executionRequest)
- } catch (e: BlueprintProcessorException) {
+ } catch (e: BluePrintProcessorException) {
kotlin.test.assertEquals(
"Can't proceed with the cfg snapshot diff: provide resource-id and resource-type.",
e.message
@@ -328,7 +328,7 @@ class ComponentConfigSnapshotsExecutorTest {
}
// then; we should get success
- assertTrue(bluePrintRuntimeService.getBlueprintError().allErrors().size == 0)
+ assertTrue(bluePrintRuntimeService.getBluePrintError().allErrors().size == 0)
assertEquals(
ComponentConfigSnapshotsExecutor.OUTPUT_STATUS_SUCCESS.asJsonPrimitive(),
bluePrintRuntimeService.getNodeTemplateAttributeValue(
@@ -368,7 +368,7 @@ class ComponentConfigSnapshotsExecutorTest {
prepareRequestProperties(OPERATION_DIFF, resId, resType, DIFF_XML)
cfgSnapshotComponent.processNB(executionRequest)
- } catch (e: BlueprintProcessorException) {
+ } catch (e: BluePrintProcessorException) {
kotlin.test.assertEquals(
"Can't proceed with the cfg snapshot diff: provide resource-id and resource-type.",
e.message
@@ -377,7 +377,7 @@ class ComponentConfigSnapshotsExecutorTest {
}
// then; we should get success
- assertTrue(bluePrintRuntimeService.getBlueprintError().allErrors().size == 0)
+ assertTrue(bluePrintRuntimeService.getBluePrintError().allErrors().size == 0)
assertEquals(
ComponentConfigSnapshotsExecutor.OUTPUT_STATUS_SUCCESS.asJsonPrimitive(),
bluePrintRuntimeService.getNodeTemplateAttributeValue(
diff --git a/ms/blueprintsprocessor/functions/config-snapshots/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/config/snapshots/TestDatabaseConfiguration.kt b/ms/blueprintsprocessor/functions/config-snapshots/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/config/snapshots/TestDatabaseConfiguration.kt
index b65191347..96045ee07 100644
--- a/ms/blueprintsprocessor/functions/config-snapshots/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/config/snapshots/TestDatabaseConfiguration.kt
+++ b/ms/blueprintsprocessor/functions/config-snapshots/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/config/snapshots/TestDatabaseConfiguration.kt
@@ -16,7 +16,7 @@
package org.onap.ccsdk.cds.blueprintsprocessor.functions.config.snapshots
-import org.onap.ccsdk.cds.blueprintsprocessor.db.BlueprintDBLibConfiguration
+import org.onap.ccsdk.cds.blueprintsprocessor.db.BluePrintDBLibConfiguration
import org.onap.ccsdk.cds.blueprintsprocessor.db.PrimaryDataSourceProperties
import org.onap.ccsdk.cds.blueprintsprocessor.db.primary.PrimaryDatabaseConfiguration
import org.springframework.context.annotation.Bean
@@ -29,7 +29,7 @@ import org.springframework.transaction.PlatformTransactionManager
import javax.sql.DataSource
@Configuration
-@Import(BlueprintDBLibConfiguration::class)
+@Import(BluePrintDBLibConfiguration::class)
@EnableJpaRepositories(
basePackages = ["org.onap.ccsdk.cds.blueprintsprocessor.functions.config.snapshots"],
entityManagerFactoryRef = "primaryEntityManager",