From 211aa04726bb1789006dde33e5755ba3894d7ed7 Mon Sep 17 00:00:00 2001 From: Claudio Atzori Date: Wed, 9 Dec 2020 18:08:51 +0100 Subject: [PATCH] allow orcid_pending to be percolate to the XML graph serialization --- .../dhp/oa/provision/CreateRelatedEntitiesJob_phase2.java | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/dhp-workflows/dhp-graph-provision/src/main/java/eu/dnetlib/dhp/oa/provision/CreateRelatedEntitiesJob_phase2.java b/dhp-workflows/dhp-graph-provision/src/main/java/eu/dnetlib/dhp/oa/provision/CreateRelatedEntitiesJob_phase2.java index 9cdf1cd2e..f3fbca47d 100644 --- a/dhp-workflows/dhp-graph-provision/src/main/java/eu/dnetlib/dhp/oa/provision/CreateRelatedEntitiesJob_phase2.java +++ b/dhp-workflows/dhp-graph-provision/src/main/java/eu/dnetlib/dhp/oa/provision/CreateRelatedEntitiesJob_phase2.java @@ -8,6 +8,7 @@ import java.util.Objects; import java.util.Optional; import java.util.stream.Collectors; +import eu.dnetlib.dhp.schema.common.ModelConstants; import org.apache.commons.io.IOUtils; import org.apache.commons.lang3.StringUtils; import org.apache.spark.SparkConf; @@ -272,11 +273,7 @@ public class CreateRelatedEntitiesJob_phase2 { .filter(Objects::nonNull) .map(Qualifier::getClassid) .filter(StringUtils::isNotBlank) - .anyMatch(c -> "orcid".equals(c.toLowerCase())); - } - - private static FilterFunction filterEmptyEntityFn() { - return (FilterFunction) v -> Objects.nonNull(v.getEntity()); + .anyMatch(c -> c.toLowerCase().contains(ModelConstants.ORCID)); } private static void removeOutputDir(SparkSession spark, String path) {