aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorsebdet <sebastien.determe@intl.att.com>2019-02-07 13:53:55 +0100
committersebdet <sebastien.determe@intl.att.com>2019-02-07 13:53:55 +0100
commit95511cbe373d5cf138689b091a1ef26c199868f8 (patch)
treeb3c75113a36e7b4d78af560457874a89cc9a8bca /src
parent95d45aa4490b09f7ddf229141501befa5a0d3d55 (diff)
Add exception for DCAE
Add exception when DCAE does not return an answer as the CSAR is not deployed in that case Issue-ID: CLAMP-291 Change-Id: Ibe2dc96f415e54c4e15b6dd57b214207e5dc22af Signed-off-by: sebdet <sebastien.determe@intl.att.com>
Diffstat (limited to 'src')
-rw-r--r--src/main/java/org/onap/clamp/clds/sdc/controller/installer/CsarInstallerImpl.java5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/main/java/org/onap/clamp/clds/sdc/controller/installer/CsarInstallerImpl.java b/src/main/java/org/onap/clamp/clds/sdc/controller/installer/CsarInstallerImpl.java
index 94cffbb7f..50090920e 100644
--- a/src/main/java/org/onap/clamp/clds/sdc/controller/installer/CsarInstallerImpl.java
+++ b/src/main/java/org/onap/clamp/clds/sdc/controller/installer/CsarInstallerImpl.java
@@ -246,6 +246,11 @@ public class CsarInstallerImpl implements CsarInstaller {
private CldsModel createFakeCldsModel(CsarHandler csar, BlueprintArtifact blueprintArtifact,
CldsTemplate cldsTemplate, DcaeInventoryResponse dcaeInventoryResponse) throws SdcArtifactInstallerException {
+
+ if (dcaeInventoryResponse == null) {
+ throw new SdcArtifactInstallerException(
+ "DCAE inventory response is NULL, query to DCAE fail to be answered properly, this is required to deploy CSAR properly !!!");
+ }
try {
CldsModel cldsModel = new CldsModel();
cldsModel.setName(buildModelName(csar, blueprintArtifact.getResourceAttached().getResourceInstanceName()));