summaryrefslogtreecommitdiffstats
path: root/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager
diff options
context:
space:
mode:
Diffstat (limited to 'openecomp-be/backend/openecomp-sdc-vendor-software-product-manager')
-rw-r--r--openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/impl/CompositionEntityDataManagerImpl.java7
1 files changed, 4 insertions, 3 deletions
diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/impl/CompositionEntityDataManagerImpl.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/impl/CompositionEntityDataManagerImpl.java
index a00bd8e967..faa53862ef 100644
--- a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/impl/CompositionEntityDataManagerImpl.java
+++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/impl/CompositionEntityDataManagerImpl.java
@@ -212,16 +212,14 @@ public class CompositionEntityDataManagerImpl implements CompositionEntityDataMa
@Override
public Set<CompositionEntityValidationData> getAllErrorsByVsp(String vspId) {
- CompositionEntityValidationData matchVsp = null;
Set<CompositionEntityValidationData> entitiesWithErrors = new HashSet<>();
for (CompositionEntityValidationData root : roots) {
if (root.getEntityId().equals(vspId)) {
- matchVsp = root;
+ getEntityListWithErrors(root, entitiesWithErrors);
break;
}
}
- getEntityListWithErrors(matchVsp, entitiesWithErrors);
if (CollectionUtils.isNotEmpty(entitiesWithErrors)) {
updateValidationCompositionEntityName(entitiesWithErrors);
return entitiesWithErrors;
@@ -449,6 +447,9 @@ public class CompositionEntityDataManagerImpl implements CompositionEntityDataMa
case vsp:
CompositionEntityData vspEntity = getCompositionEntityDataById(entity);
+ if (Objects.isNull(vspEntity)) {
+ return null;
+ }
VspQuestionnaireEntity vspQuestionnaireEntity = (VspQuestionnaireEntity) vspEntity.entity;
VspDetails vspDetails =
vspInfoDao.get(new VspDetails(vspQuestionnaireEntity.getId(),