geosolutions-it/ckanext-dataverse

Handle harvester configuration

Opened this issue · 0 comments

etj commented

Parse the harvester json configuration in order to be able to get parameters from it.

The configuration may be something like:

{
   "filter": "the_filter",
   "id_field_name": "global_id"
}
  • filter: (default *) the filter to apply in the search URL
  • id_field_name: (default identifier) the field in the item json to be used as a unique identifier for the dataset

If the configuration does not exist, or a single field does not exist, the related default value will be used.

We need that the URL of the harvester will be simply the base URL.
e.g.
https://demo.dataverse.org

The logic will create the final query URL as
https://demo.dataverse.org/api/search?q=the_filter
hiding the API path to the harvest URL