summaryrefslogtreecommitdiffstats
path: root/mso-catalog-db/src
diff options
context:
space:
mode:
Diffstat (limited to 'mso-catalog-db/src')
-rw-r--r--mso-catalog-db/src/main/java/org/onap/so/db/catalog/beans/CvnfcCustomization.java7
-rw-r--r--mso-catalog-db/src/main/java/org/onap/so/db/catalog/data/repository/CvnfcConfigurationCustomizationRepository.java3
-rw-r--r--mso-catalog-db/src/test/java/org/onap/so/db/catalog/beans/CvnfcCustomizationTest.java4
3 files changed, 10 insertions, 4 deletions
diff --git a/mso-catalog-db/src/main/java/org/onap/so/db/catalog/beans/CvnfcCustomization.java b/mso-catalog-db/src/main/java/org/onap/so/db/catalog/beans/CvnfcCustomization.java
index da3e391e11..7fb328fdb5 100644
--- a/mso-catalog-db/src/main/java/org/onap/so/db/catalog/beans/CvnfcCustomization.java
+++ b/mso-catalog-db/src/main/java/org/onap/so/db/catalog/beans/CvnfcCustomization.java
@@ -22,6 +22,7 @@ package org.onap.so.db.catalog.beans;
import java.io.Serializable;
import java.util.Date;
+import java.util.List;
import java.util.Set;
import javax.persistence.CascadeType;
import javax.persistence.Column;
@@ -100,7 +101,7 @@ public class CvnfcCustomization implements Serializable {
private VnfcCustomization vnfcCustomization;
@OneToMany(cascade = CascadeType.ALL, mappedBy = "cvnfcCustomization")
- private Set<CvnfcConfigurationCustomization> cvnfcConfigurationCustomization;
+ private List<CvnfcConfigurationCustomization> cvnfcConfigurationCustomization;
@Override
public boolean equals(final Object other) {
@@ -142,12 +143,12 @@ public class CvnfcCustomization implements Serializable {
}
@LinkedResource
- public Set<CvnfcConfigurationCustomization> getCvnfcConfigurationCustomization() {
+ public List<CvnfcConfigurationCustomization> getCvnfcConfigurationCustomization() {
return cvnfcConfigurationCustomization;
}
public void setCvnfcConfigurationCustomization(
- Set<CvnfcConfigurationCustomization> cvnfcConfigurationCustomization) {
+ List<CvnfcConfigurationCustomization> cvnfcConfigurationCustomization) {
this.cvnfcConfigurationCustomization = cvnfcConfigurationCustomization;
}
diff --git a/mso-catalog-db/src/main/java/org/onap/so/db/catalog/data/repository/CvnfcConfigurationCustomizationRepository.java b/mso-catalog-db/src/main/java/org/onap/so/db/catalog/data/repository/CvnfcConfigurationCustomizationRepository.java
index 1e5a07350d..d974e88890 100644
--- a/mso-catalog-db/src/main/java/org/onap/so/db/catalog/data/repository/CvnfcConfigurationCustomizationRepository.java
+++ b/mso-catalog-db/src/main/java/org/onap/so/db/catalog/data/repository/CvnfcConfigurationCustomizationRepository.java
@@ -20,6 +20,7 @@
package org.onap.so.db.catalog.data.repository;
+import java.util.List;
import org.onap.so.db.catalog.beans.CvnfcConfigurationCustomization;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.rest.core.annotation.RepositoryRestResource;
@@ -29,4 +30,6 @@ import org.springframework.data.rest.core.annotation.RepositoryRestResource;
public interface CvnfcConfigurationCustomizationRepository
extends JpaRepository<CvnfcConfigurationCustomization, Integer> {
+ List<CvnfcConfigurationCustomization> findByModelCustomizationUUID(String modelCustomizationUUID);
+
}
diff --git a/mso-catalog-db/src/test/java/org/onap/so/db/catalog/beans/CvnfcCustomizationTest.java b/mso-catalog-db/src/test/java/org/onap/so/db/catalog/beans/CvnfcCustomizationTest.java
index 80e3d53c57..4010328ad9 100644
--- a/mso-catalog-db/src/test/java/org/onap/so/db/catalog/beans/CvnfcCustomizationTest.java
+++ b/mso-catalog-db/src/test/java/org/onap/so/db/catalog/beans/CvnfcCustomizationTest.java
@@ -21,7 +21,9 @@
package org.onap.so.db.catalog.beans;
import static org.junit.Assert.assertTrue;
+import java.util.ArrayList;
import java.util.HashSet;
+import java.util.List;
import java.util.Set;
import org.junit.Test;
@@ -54,7 +56,7 @@ public class CvnfcCustomizationTest {
cvnfcCustomization.setNfcNamingCode(NFC_NAMING_CODE);
cvnfcCustomization.setToscaNodeType(TOSCA_NODE_TYPE);
cvnfcCustomization.setVfModuleCustomization(setupVfModuleCustomization());
- Set<CvnfcConfigurationCustomization> cvnfcConfigurationCustomizationSet = new HashSet();
+ List<CvnfcConfigurationCustomization> cvnfcConfigurationCustomizationSet = new ArrayList();
cvnfcConfigurationCustomizationSet.add(setupCvnfcConfigurationCustomization());
cvnfcCustomization.setCvnfcConfigurationCustomization(cvnfcConfigurationCustomizationSet);