Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add the DCAT2 schema plugin #183

Merged
merged 5 commits into from
Sep 23, 2021

Conversation

jahow
Copy link
Contributor

@jahow jahow commented Sep 8, 2021

Followed instructions here: https://github.com/geonetwork/core-geonetwork/wiki/GeoNetwork-DCAT2-codesprint-April-2021#development

To do:

@jahow
Copy link
Contributor Author

jahow commented Sep 8, 2021

Here are the problems I encountered in my tests:

  • keywords not working (no autocomplete, free text not saved)
    image

  • spatial and temporal extents saved but not appearing in simple view

  • no validation in editor

  • no multilingual validation

  • no full view

  • value entered in "landing page" not saved sometimes
    image

  • "concepts" not saved
    image

  • in simple view, catalog record info (title, abstract) and dataset description (title, description) are seemingly mixed up:
    image

This is the dcat record used:

<?xml version="1.0" encoding="UTF-8"?>
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
         xmlns:skos="http://www.w3.org/2004/02/skos/core#"
         xmlns:foaf="http://xmlns.com/foaf/0.1/"
         xmlns:dct="http://purl.org/dc/terms/"
         xmlns:vcard="http://www.w3.org/2006/vcard/ns#"
         xmlns:dcat="http://www.w3.org/ns/dcat#"
         xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#"
         xmlns:spdx="http://spdx.org/rdf/terms#"
         xmlns:adms="http://www.w3.org/ns/adms#"
         xmlns:prov="http://www.w3.org/ns/prov#"
         xmlns:owl="http://www.w3.org/2002/07/owl#"
         xmlns:schema="http://schema.org/"
         xmlns:locn="http://www.w3.org/ns/locn#"
         xmlns:gml="http://www.opengis.net/gml/3.2"
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xsi:schemaLocation="http://www.w3.org/1999/02/22-rdf-syntax-ns# http://localhost:8080/geonetwork/xml/schemas/dcat2/schema.xsd">
  <dcat:CatalogRecord rdf:about="http://localhost:8080/geonetwork/srv/api/records/837ac693-6803-4998-902f-76826ee7f9cf">
      <dct:identifier>837ac693-6803-4998-902f-76826ee7f9cf</dct:identifier>
      <dct:issued>2021-09-08T15:51:59.446Z</dct:issued>
      <dct:modified>2021-09-08T16:10:12.729Z</dct:modified>
      <dct:title>My test data title</dct:title>
      <dct:description>A description full of words.</dct:description>
      <dct:language rdf:resource="http://id.loc.gov/vocabulary/iso639-2/eng"/>
  </dcat:CatalogRecord>
  <dcat:Dataset>
      <dct:title>Test data</dct:title>
      <dct:description>Very good data indeaad</dct:description>
      <dcat:theme>
         <skos:Concept rdf:about="http://publications.europa.eu/resource/authority/data-theme/OP_DATPRO">
            <skos:prefLabel xml:lang="eng">Provisional data</skos:prefLabel>
            <skos:inScheme rdf:resource="http://publications.europa.eu/resource/authority/data-theme"/>
         </skos:Concept>
      </dcat:theme>
      <dcat:theme>
         <skos:Concept rdf:about="http://publications.europa.eu/resource/authority/data-theme/ENVI">
            <skos:prefLabel xml:lang="eng">Environment</skos:prefLabel>
            <skos:inScheme rdf:resource="http://publications.europa.eu/resource/authority/data-theme"/>
         </skos:Concept>
      </dcat:theme>
      <dct:type>
         <skos:Concept rdf:about="https://registry.geonetwork-opensource.org/dcat/type/dataset">
            <skos:prefLabel xml:lang="eng">Dataset</skos:prefLabel>
            <skos:inScheme rdf:resource="https://registry.geonetwork-opensource.org/dcat/type"/>
         </skos:Concept>
      </dct:type>
      <dct:issued rdf:datatype="http://www.w3.org/2001/XMLSchema#date">2021-09-08</dct:issued>
      <dct:spatial>
         <dct:Location>
            <locn:geometry rdf:datatype="http://www.opengis.net/ont/geosparql#wktLiteral">POLYGON ((3.6352 47.1146,3.6352 52.5493,-5.857 52.5493,-5.857 47.1146,3.6352 47.1146))</locn:geometry>
            <locn:geometry rdf:datatype="http://www.opengis.net/ont/geosparql#gmlLiteral">&lt;gml:Polygon xmlns:gml="http://www.opengis.net/gml/3.2"&gt;&lt;gml:exterior&gt;&lt;gml:LinearRing&gt;&lt;gml:posList&gt;47.1146 3.6352 52.5493 3.6352 52.5493 -5.857 47.1146 -5.857 47.1146 3.6352&lt;/gml:posList&gt;&lt;/gml:LinearRing&gt;&lt;/gml:exterior&gt;&lt;/gml:Polygon&gt;</locn:geometry>
         </dct:Location>
      </dct:spatial>
      <dct:temporal>
         <dct:PeriodOfTime>
            <schema:startDate rdf:datatype="http://www.w3.org/2001/XMLSchema#date">2021-09-01</schema:startDate>
            <schema:endDate rdf:datatype="http://www.w3.org/2001/XMLSchema#date">2021-09-07</schema:endDate>
         </dct:PeriodOfTime>
      </dct:temporal>
      <dct:accessRights>
         <skos:Concept rdf:about="http://publications.europa.eu/resource/authority/access-right/PUBLIC">
            <rdf:type rdf:resource="http://purl.org/dc/terms/RightsStatement"/>
            <skos:prefLabel xml:lang="eng">public</skos:prefLabel>
            <skos:inScheme rdf:resource="http://publications.europa.eu/resource/authority/access-right"/>
         </skos:Concept>
      </dct:accessRights>
      <dcat:landingPage>
         <foaf:Document rdf:about="https://www.google.com"/>
      </dcat:landingPage>
      <dcat:distribution>
         <dcat:Distribution>
            <dct:description>Screenshot%20from%202021-03-30%2013-53-04.png</dct:description>
            <dcat:accessURL>http://localhost:8080/geonetwork/srv/api/records/837ac693-6803-4998-902f-76826ee7f9cf/attachments/Screenshot%20from%202021-03-30%2013-53-04.png</dcat:accessURL>
            <dct:format>
               <skos:Concept>
                  <rdf:type rdf:resource="http://purl.org/dc/terms/MediaTypeOrExtent"/>
                  <skos:prefLabel>WWW:OVERVIEW</skos:prefLabel>
               </skos:Concept>
            </dct:format>
         </dcat:Distribution>
      </dcat:distribution>
      <dcat:distribution>
         <dcat:Distribution>
            <dcat:downloadURL>http://localhost:8080/geonetwork/srv/api/records/837ac693-6803-4998-902f-76826ee7f9cf/attachments/surval_parametre_point.geojson</dcat:downloadURL>
            <dct:description>surval_parametre_point.geojson</dct:description>
            <dct:format>
               <skos:Concept>
                  <rdf:type rdf:resource="http://purl.org/dc/terms/MediaTypeOrExtent"/>
                  <skos:prefLabel>WWW:DOWNLOAD</skos:prefLabel>
               </skos:Concept>
            </dct:format>
         </dcat:Distribution>
      </dcat:distribution>
      <dcat:spatialResolutionInMeters>0.25</dcat:spatialResolutionInMeters>
      <dcat:temporalResolution>P0Y0M1DT0H0M0S</dcat:temporalResolution>
  </dcat:Dataset>
</rdf:RDF>

@fgravin
Copy link
Member

fgravin commented Sep 8, 2021

@jeanpommier @fxprunayre you have worked on the plugin, could you please react on @jahow outputs about what seems to miss in the dcat editor, are we missing some confirmation, or is it well known that the feature is not implemented ?
Thanks

@jahow I think we should go for a submodule instead ? So we can contribute the enhancements/fixes we're going to make within the schema.

@fgravin
Copy link
Member

fgravin commented Sep 8, 2021

Here are the problems I encountered in my tests:

Find the current status on the plugin
https://github.com/metadata101/dcat2/projects/1

@jeanpommier
Copy link
Member

Here are the problems I encountered in my tests:

* keywords not working (no autocomplete, free text not saved)

To have the keywords autocompletion, you have to enable the virtual "all" thesaurus. This was an opinionated (and discussed) choice: to keep the edition ultra simple, we choose to limit the keywords entry to a single thesaurus.

Taken from https://github.com/metadata101/dcat2

* added schema as a submodule
* added module reference in gn-schemas
* added dependency and artifact refs in web module
@jahow jahow force-pushed the georchestra/georchestra-gn4-dcat branch from 313cbaf to 4ad23c0 Compare September 9, 2021 08:46
@jahow
Copy link
Contributor Author

jahow commented Sep 9, 2021

@jahow I think we should go for a submodule instead ? So we can contribute the enhancements/fixes we're going to make within the schema.

it is now a submodule.

This commit is a squash of geonetwork/core-geonetwork#5942

A simple harvester which takes a URL expecting for now a JSON document
and loop over document identified by a JSONPointer and applying an XSL
to convert to ISO format.

This should allow GeoNetwork to harvest some of the opendata portal
providing all various search API providing JSON response usually.

Harvester / Simple URL / Paging and basic opendatasoft support.

Json harvester: fix merge conflicts

jsonHarvester: handle JSONLD format with @ in tag names

jsonHarvester: add ESRI JSONLD DCAT transformation

hack: to remove, extract uuid from URIs

jsonHarvester: extract uuid from identifier

https://data-atmo-hdf.opendata.arcgis.com/datasets/bac17d7d05a34242a8b22c535ecdb13d
will extract bac17d7d05a34242a8b22c535ecdb13d
@jahow jahow force-pushed the georchestra/georchestra-gn4-dcat branch from 4ad23c0 to 4918e66 Compare September 9, 2021 10:00
jahow and others added 3 commits September 9, 2021 17:10
The DCAT2 plugin now points to a forked branch containing an ESRI DCAT
conversion xsl
used by ODS to compute exports links
@fgravin fgravin force-pushed the georchestra/georchestra-gn4-dcat branch from 98f941a to 052ac47 Compare September 13, 2021 07:35
@fgravin fgravin changed the title [WIP] Add the DCAT2 schema plugin Add the DCAT2 schema plugin Sep 23, 2021
@fgravin fgravin merged commit 9e5118f into georchestra-gn4-4.x-dev Sep 23, 2021
@fgravin fgravin deleted the georchestra/georchestra-gn4-dcat branch September 23, 2021 10:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants