From 38ac58ba86b899f8d57c5e4b3d6b54a1092dc969 Mon Sep 17 00:00:00 2001 From: vasraz Date: Wed, 29 Apr 2020 14:13:18 +0100 Subject: Fix VFs and Service not visible in SDC Dashboard Change-Id: Ia42775388c3ad9539b7d0020476f0f7a91ce8bb9 Signed-off-by: Vasyl Razinkov Issue-ID: SDC-2938 --- .../java/org/openecomp/sdc/be/model/Component.java | 18 ++++++------------ .../main/java/org/openecomp/sdc/be/model/Service.java | 12 ++---------- 2 files changed, 8 insertions(+), 22 deletions(-) diff --git a/catalog-model/src/main/java/org/openecomp/sdc/be/model/Component.java b/catalog-model/src/main/java/org/openecomp/sdc/be/model/Component.java index 7d4dfa72f4..bf1dfef243 100644 --- a/catalog-model/src/main/java/org/openecomp/sdc/be/model/Component.java +++ b/catalog-model/src/main/java/org/openecomp/sdc/be/model/Component.java @@ -57,7 +57,7 @@ import org.openecomp.sdc.common.log.api.ILogConfiguration; @Getter @Setter -@EqualsAndHashCode +@EqualsAndHashCode(onlyExplicitlyIncluded = true) public abstract class Component implements PropertiesOwner { protected List additionalInformation; @@ -66,6 +66,7 @@ public abstract class Component implements PropertiesOwner { private Map artifacts; private Map deploymentArtifacts; private Map toscaArtifacts; + @EqualsAndHashCode.Include private List categories; private List componentInstances; private List componentInstancesRelations; @@ -82,8 +83,6 @@ public abstract class Component implements PropertiesOwner { private String derivedFromGenericVersion; private String toscaType; private Map nodeFilterComponents; - private Map> nodeFilters; - private Map> serviceFilters; private Map interfaces; private List dataTypes; @@ -97,6 +96,7 @@ public abstract class Component implements PropertiesOwner { } @Override + @EqualsAndHashCode.Include public String getUniqueId() { return componentMetadataDefinition.getMetadataDataDefinition().getUniqueId(); } @@ -146,6 +146,7 @@ public abstract class Component implements PropertiesOwner { } @Override + @EqualsAndHashCode.Include public String getName() { return componentMetadataDefinition.getMetadataDataDefinition().getName(); } @@ -272,6 +273,7 @@ public abstract class Component implements PropertiesOwner { } @Override + @EqualsAndHashCode.Include public String getNormalizedName() { return componentMetadataDefinition.getMetadataDataDefinition().getNormalizedName(); } @@ -325,15 +327,6 @@ public abstract class Component implements PropertiesOwner { .collect(Collectors.toList()); } - public Map> getComponentInstancesProperties() { - return componentInstancesProperties; - } - - public void setComponentInstancesProperties( - Map> resourceInstancesProperties) { - this.componentInstancesProperties = resourceInstancesProperties; - } - public Map> safeGetComponentInstancesProperties() { return componentInstancesProperties == null ? emptyMap() : componentInstancesProperties; } @@ -611,6 +604,7 @@ public abstract class Component implements PropertiesOwner { return cmptInstanceProps == null ? emptyPropsList : cmptInstanceProps; } + public void setSpecificComponetTypeArtifacts(Map specificComponentTypeArtifacts) { // Implement where needed } diff --git a/catalog-model/src/main/java/org/openecomp/sdc/be/model/Service.java b/catalog-model/src/main/java/org/openecomp/sdc/be/model/Service.java index 8168e73f01..3040f6bb6c 100644 --- a/catalog-model/src/main/java/org/openecomp/sdc/be/model/Service.java +++ b/catalog-model/src/main/java/org/openecomp/sdc/be/model/Service.java @@ -25,6 +25,7 @@ import java.util.Map; import lombok.EqualsAndHashCode; import lombok.Getter; import lombok.Setter; +import lombok.ToString; import org.apache.commons.lang.StringUtils; import org.openecomp.sdc.be.datatypes.components.ComponentMetadataDataDefinition; import org.openecomp.sdc.be.datatypes.components.ServiceMetadataDataDefinition; @@ -36,6 +37,7 @@ import org.openecomp.sdc.be.model.jsonjanusgraph.datamodel.ToscaElementTypeEnum; @Getter @Setter @EqualsAndHashCode(callSuper = true) +@ToString public class Service extends Component { private Map serviceApiArtifacts; @@ -155,16 +157,6 @@ public class Service extends Component { } } - @Override - public String toString() { - return "Service [componentMetadataDefinition=" + getComponentMetadataDefinition() - // + ", resourceInstances=" + resourceInstances + ", - // resourceInstancesRelations=" + resourceInstancesRelations + ", - // resourceInstancesRelations=" - // + resourceInstancesRelations - + " ]"; - } - @Override public void setSpecificComponetTypeArtifacts(Map specificComponentTypeArtifacts) { setServiceApiArtifacts(specificComponentTypeArtifacts); -- cgit 1.2.3-korg