From 2e0ee01237f8aa880a4d04d26ce570b441a38781 Mon Sep 17 00:00:00 2001 From: Jan van Zadelhoff Date: Wed, 2 Dec 2020 15:44:28 +0100 Subject: [PATCH] add configuration flag to toggle the sorting of the results --- README.md | 1 + pom.xml | 1 + src/main/resources/camel-oai-pmh.properties | 1 + src/main/resources/camel-oai-pmh.xml | 3 +++ src/main/resources/inspireRequest.xsl | 15 +++++++++------ 5 files changed, 15 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index 3a91a45..4de705d 100644 --- a/README.md +++ b/README.md @@ -49,6 +49,7 @@ The available parameters in the camel-oai-pmh.properties file are: * oai-pmh.dcatde.contributorID: [dcatde:contributorID](https://www.dcat-ap.de/def/contributors/) which is to be inserted in all DCAT datasets * oai-pmh.db.item.csw.TYPE: should be one of inspire, inspireSoap11 or inspireSoap11, depending on the protocol of the Geoportal * oai-pmh.db.item.csw.URL: GetRecords URL of the geoportal to be harvested +* oai-pmh.db.item.csw.sortResults: toggle whether the results should be sorted or not. Possible values are `true` and `false`. Defaults to `false`. * oai-pmh.db.item.ckan.TYPE: currently only ckan is supported * oai-pmh.db.item.ckan.URL: CKAN catalog URL to be harvested diff --git a/pom.xml b/pom.xml index a4983d0..eea85a8 100644 --- a/pom.xml +++ b/pom.xml @@ -246,6 +246,7 @@ http://localhost:8080/omdf inspire https://localhost:8080/soapServices/CSWStartup + false ckan https://localhost:9090 http://dcat-ap.de/def/contributors/gdiDE diff --git a/src/main/resources/camel-oai-pmh.properties b/src/main/resources/camel-oai-pmh.properties index b67b45d..9250a1b 100644 --- a/src/main/resources/camel-oai-pmh.properties +++ b/src/main/resources/camel-oai-pmh.properties @@ -2,6 +2,7 @@ harvester.base.url=${oai-pmh.base.url.external}/harvesters/ rdf.catalog.base.url=${oai-pmh.base.url.external}/gp-csw/catalog.rdf db.item.csw.TYPE=${oai-pmh.db.item.csw.TYPE} db.item.csw.URL=${oai-pmh.db.item.csw.URL} +db.item.csw.sortResults=${oai-pmh.db.item.csw.sortResults} db.item.ckan.TYPE=${oai-pmh.db.item.ckan.TYPE} db.item.ckan.URL=${oai-pmh.db.item.ckan.URL} dcatde.contributorID=${oai-pmh.dcatde.contributorID} diff --git a/src/main/resources/camel-oai-pmh.xml b/src/main/resources/camel-oai-pmh.xml index 0337aaf..aeb875e 100644 --- a/src/main/resources/camel-oai-pmh.xml +++ b/src/main/resources/camel-oai-pmh.xml @@ -93,6 +93,9 @@ {{dcatde.contributorID}} + + {{db.item.csw.sortResults}} + diff --git a/src/main/resources/inspireRequest.xsl b/src/main/resources/inspireRequest.xsl index ce8206e..ec2e443 100644 --- a/src/main/resources/inspireRequest.xsl +++ b/src/main/resources/inspireRequest.xsl @@ -19,6 +19,7 @@ + @@ -193,12 +194,14 @@ - - - apiso:Identifier - ASC - - + + + + apiso:Identifier + ASC + + +