diff --git a/dnet-ariadneplus-graphdb-publisher/src/main/java/eu/dnetlib/ariadneplus/elasticsearch/BulkUpload.java b/dnet-ariadneplus-graphdb-publisher/src/main/java/eu/dnetlib/ariadneplus/elasticsearch/BulkUpload.java index eed24d7..aae28c5 100644 --- a/dnet-ariadneplus-graphdb-publisher/src/main/java/eu/dnetlib/ariadneplus/elasticsearch/BulkUpload.java +++ b/dnet-ariadneplus-graphdb-publisher/src/main/java/eu/dnetlib/ariadneplus/elasticsearch/BulkUpload.java @@ -126,10 +126,10 @@ public class BulkUpload { Double.parseDouble(p.getLon()), Double.parseDouble(p.getLat())); }); - PolygonBuilder polygonBuilder = new PolygonBuilder(coordinatesBuilder); - String wkt = polygonBuilder.toWKT(); - log.debug("POLYGON "+wkt); - s.setPolygon(wkt); +// PolygonBuilder polygonBuilder = new PolygonBuilder(coordinatesBuilder); +// String wkt = polygonBuilder.toWKT(); +// log.debug("POLYGON "+wkt); +// s.setPolygon(wkt); }); ace.getSpatial() .stream() diff --git a/dnet-ariadneplus-graphdb-publisher/src/main/java/eu/dnetlib/ariadneplus/elasticsearch/model/AriadnePlusEntry.java b/dnet-ariadneplus-graphdb-publisher/src/main/java/eu/dnetlib/ariadneplus/elasticsearch/model/AriadnePlusEntry.java index 5b8b875..d3be760 100644 --- a/dnet-ariadneplus-graphdb-publisher/src/main/java/eu/dnetlib/ariadneplus/elasticsearch/model/AriadnePlusEntry.java +++ b/dnet-ariadneplus-graphdb-publisher/src/main/java/eu/dnetlib/ariadneplus/elasticsearch/model/AriadnePlusEntry.java @@ -225,7 +225,7 @@ public class AriadnePlusEntry { } public void setWasCreated(String wasCreated) { - this.wasCreated = wasCreated; + this.wasCreated = ESUtils.getESFormatDate(wasCreated); } public String getUniqueIsPartOf() { diff --git a/dnet-ariadneplus-graphdb-publisher/src/main/resources/application.properties b/dnet-ariadneplus-graphdb-publisher/src/main/resources/application.properties index 6e87911..1f92354 100644 --- a/dnet-ariadneplus-graphdb-publisher/src/main/resources/application.properties +++ b/dnet-ariadneplus-graphdb-publisher/src/main/resources/application.properties @@ -170,6 +170,11 @@ class.map.specifications={\ "class_field": "Institution",\ "substring": "no",\ "element_type": "java.lang.String"\ +},\ +"https://www.ariadne-infrastructure.eu/property/agentIdentifier": {\ +"class_field": "AgentIdentifier",\ +"substring": "no",\ +"element_type": "java.lang.String"\ }\ }\ },\ @@ -246,6 +251,11 @@ class.map.specifications={\ "element_type": "java.lang.String",\ "substring": "no"\ },\ +"https://www.ariadne-infrastructure.eu/property/created": {\ +"class_field": "WasCreated",\ +"element_type": "java.lang.String",\ +"substring": "no"\ +},\ "https://www.ariadne-infrastructure.eu/property/resourceType": {\ "class_field": "ResourceType",\ "element_type": "java.lang.String",\ diff --git a/dnet-ariadneplus-graphdb-publisher/src/main/resources/eu/dnetlib/ariadneplus/sparql/read_collection_data_template.sparql b/dnet-ariadneplus-graphdb-publisher/src/main/resources/eu/dnetlib/ariadneplus/sparql/read_collection_data_template.sparql index d40b53d..1165ca3 100644 --- a/dnet-ariadneplus-graphdb-publisher/src/main/resources/eu/dnetlib/ariadneplus/sparql/read_collection_data_template.sparql +++ b/dnet-ariadneplus-graphdb-publisher/src/main/resources/eu/dnetlib/ariadneplus/sparql/read_collection_data_template.sparql @@ -12,22 +12,38 @@ CONSTRUCT { %record aoprop:originalId ?originalId . %record aoprop:issued ?issued . %record aoprop:modified ?modified . +%record aoprop:created ?created . %record aoprop:partOf ?partOf . %record aoprop:creator ?creator . ?creator aoprop:name ?creatorName . ?creator aoprop:email ?creatorEmail . +?creator aoprop:homepage ?creatorHomepage . +?creator aoprop:institution ?creatorInstitution . +?creator aoprop:agentIdentifier ?creator . %record aoprop:contributor ?contributor . ?contributor aoprop:name ?contributorName . ?contributor aoprop:email ?contributorEmail . +?contributor aoprop:homepage ?contributorHomepage . +?contributor aoprop:institution ?contributorInstitution . +?contributor aoprop:agentIdentifier ?contributor . %record aoprop:legalResponsible ?legalResponsible . ?legalResponsible aoprop:name ?legalResponsibleName . ?legalResponsible aoprop:email ?legalResponsibleEmail . +?legalResponsible aoprop:homepage ?legalResponsibleHomepage . +?legalResponsible aoprop:institution ?legalResponsibleInstitution . +?legalResponsible aoprop:agentIdentifier ?legalResponsible . %record aoprop:owner ?owner . ?owner aoprop:name ?ownerName . ?owner aoprop:email ?ownerEmail . +?owner aoprop:homepage ?ownerHomepage . +?owner aoprop:institution ?ownerInstitution . +?owner aoprop:agentIdentifier ?owner . %record aoprop:publisher ?publisher . ?publisher aoprop:name ?publisherName . ?publisher aoprop:email ?publisherEmail . +?publisher aoprop:homepage ?publisherHomepage . +?publisher aoprop:institution ?publisherInstitution . +?publisher aoprop:agentIdentifier ?publisher . %record aoprop:accessPolicy ?accessPolicy . %record aoprop:accessRights ?accessRights . %record aoprop:landingPage ?landingPage . @@ -156,18 +172,45 @@ where { %record aocat:has_access_rights ?accessRights . %record aocat:has_ARIADNE_subject ?archeologicalResourceType . ?archeologicalResourceType skos:prefLabel ?archeologicalResourceTypeName . + optional { + %record aocat:was_created_on ?created . + } optional { ?contributor aocat:has_email ?contributorEmail . } + optional { + ?contributor aocat:has_homepage ?contributorHomepage . + } + optional { + ?contributor aocat:has_institution ?contributorInstitution . + } optional { ?legalResponsible aocat:has_email ?legalResponsibleEmail . } + optional { + ?legalResponsible aocat:has_homepage ?legalResponsibleHomepage . + } + optional { + ?legalResponsible aocat:has_institution ?legalResponsibleInstitution . + } optional { ?owner aocat:has_email ?ownerEmail . } + optional { + ?owner aocat:has_homepage ?ownerHomepage . + } + optional { + ?owner aocat:has_institution ?ownerInstitution . + } optional { ?publisher aocat:has_email ?publisherEmail . } + optional { + ?publisher aocat:has_homepage ?publisherHomepage . + } + optional { + ?publisher aocat:has_institution ?publisherInstitution . + } } } } diff --git a/dnet-ariadneplus-graphdb-publisher/src/main/resources/eu/dnetlib/ariadneplus/sparql/read_record_data_template.sparql b/dnet-ariadneplus-graphdb-publisher/src/main/resources/eu/dnetlib/ariadneplus/sparql/read_record_data_template.sparql index 86dc7ae..7ff7eab 100644 --- a/dnet-ariadneplus-graphdb-publisher/src/main/resources/eu/dnetlib/ariadneplus/sparql/read_record_data_template.sparql +++ b/dnet-ariadneplus-graphdb-publisher/src/main/resources/eu/dnetlib/ariadneplus/sparql/read_record_data_template.sparql @@ -12,22 +12,38 @@ CONSTRUCT { %record aoprop:originalId ?originalId . %record aoprop:issued ?issued . %record aoprop:modified ?modified . +%record aoprop:created ?created . %record aoprop:partOf ?partOf . %record aoprop:creator ?creator . ?creator aoprop:name ?creatorName . ?creator aoprop:email ?creatorEmail . +?creator aoprop:homepage ?creatorHomepage . +?creator aoprop:institution ?creatorInstitution . +?creator aoprop:agentIdentifier ?creator . %record aoprop:contributor ?contributor . ?contributor aoprop:name ?contributorName . ?contributor aoprop:email ?contributorEmail . +?contributor aoprop:homepage ?contributorHomepage . +?contributor aoprop:institution ?contributorInstitution . +?contributor aoprop:agentIdentifier ?contributor . %record aoprop:legalResponsible ?legalResponsible . ?legalResponsible aoprop:name ?legalResponsibleName . ?legalResponsible aoprop:email ?legalResponsibleEmail . +?legalResponsible aoprop:homepage ?legalResponsibleHomepage . +?legalResponsible aoprop:institution ?legalResponsibleInstitution . +?legalResponsible aoprop:agentIdentifier ?legalResponsible . %record aoprop:owner ?owner . ?owner aoprop:name ?ownerName . ?owner aoprop:email ?ownerEmail . +?owner aoprop:homepage ?ownerHomepage . +?owner aoprop:institution ?ownerInstitution . +?owner aoprop:agentIdentifier ?owner . %record aoprop:publisher ?publisher . ?publisher aoprop:name ?publisherName . ?publisher aoprop:email ?publisherEmail . +?publisher aoprop:homepage ?publisherHomepage . +?publisher aoprop:institution ?publisherInstitution . +?publisher aoprop:agentIdentifier ?publisher . %record aoprop:accessPolicy ?accessPolicy . %record aoprop:accessRights ?accessRights . %record aoprop:landingPage ?landingPage . @@ -142,18 +158,45 @@ where { %record aocat:has_access_rights ?accessRights . %record aocat:has_ARIADNE_subject ?archeologicalResourceType . ?archeologicalResourceType skos:prefLabel ?archeologicalResourceTypeName . + optional { + %record aocat:was_created_on ?created . + } optional { ?contributor aocat:has_email ?contributorEmail . } + optional { + ?contributor aocat:has_homepage ?contributorHomepage . + } + optional { + ?contributor aocat:has_institution ?contributorInstitution . + } optional { ?legalResponsible aocat:has_email ?legalResponsibleEmail . } + optional { + ?legalResponsible aocat:has_homepage ?legalResponsibleHomepage . + } + optional { + ?legalResponsible aocat:has_institution ?legalResponsibleInstitution . + } optional { ?owner aocat:has_email ?ownerEmail . } + optional { + ?owner aocat:has_homepage ?ownerHomepage . + } + optional { + ?owner aocat:has_institution ?ownerInstitution . + } optional { ?publisher aocat:has_email ?publisherEmail . } + optional { + ?publisher aocat:has_homepage ?publisherHomepage . + } + optional { + ?publisher aocat:has_institution ?publisherInstitution . + } } } }