diff --git a/ingestion/src/main/java/feast/ingestion/model/Specs.java b/ingestion/src/main/java/feast/ingestion/model/Specs.java index 085fcc9436..5189f63130 100644 --- a/ingestion/src/main/java/feast/ingestion/model/Specs.java +++ b/ingestion/src/main/java/feast/ingestion/model/Specs.java @@ -19,6 +19,7 @@ import com.google.common.base.Preconditions; import com.google.common.collect.Lists; +import com.google.common.collect.Sets; import feast.ingestion.service.SpecService; import feast.specs.EntitySpecProto.EntitySpec; import feast.specs.FeatureSpecProto.FeatureSpec; @@ -30,6 +31,7 @@ import java.util.List; import java.util.Map; import java.util.Map.Entry; +import java.util.Set; import lombok.Builder; import lombok.Getter; import lombok.ToString; @@ -63,7 +65,7 @@ public static Specs of(String jobName, ImportSpec importSpec, SpecService specSe specsBuilder.featureSpecs(specService.getFeatureSpecs(featureIds)); List entityNames = importSpec.getEntitiesList(); - List storageIds = Lists.newArrayList(); + Set storageIds = Sets.newHashSet(); for (FeatureSpec featureSpec : specsBuilder.featureSpecs.values()) { Preconditions.checkArgument( entityNames.contains(featureSpec.getEntity()),