OAI-PMH Support (UXPROD-993)

[MODOAIPMH-15] OAI-PMH: Implement verb "Identify" Created: 28/Sep/18  Updated: 14/Nov/18  Resolved: 29/Oct/18

Status: Closed
Project: mod-oai-pmh
Components: None
Affects versions: None
Fix versions: 1.0.0
Parent: OAI-PMH Support

Type: Story Priority: P2
Reporter: Hkaplanian Assignee: Hkaplanian
Resolution: Done Votes: 0
Labels: epam-thunderjet
Σ Remaining Estimate: Not Specified Remaining Estimate: Not Specified
Σ Time Spent: Not Specified Time Spent: Not Specified
Σ Original Estimate: Not Specified Original estimate: Not Specified

Issue links:
Relates
relates to MODOAIPMH-61 OAI-PMH: oai-identifier description a... Closed
relates to UXPROD-350 OAI-PMH Support Closed
Sub-tasks:
Key
Summary
Type
Status
Assignee
MODOAIPMH-34 Implementation Sub-task Closed Piotr Kalashuk  
MODOAIPMH-35 Error conditions Sub-task Closed Craig McNally  
Sprint: oai-pmh - sprint 49
Story Points: 5
Development Team: Thunderjet
Epic Link: OAI-PMH Support

 Description   

Official specification: https://www.openarchives.org/OAI/openarchivesprotocol.html#Identify

1. Implementation
2. Error conditions



 Comments   
Comment by Craig McNally [ 15/Oct/18 ]

Piotr Kalashuk From the "implementation" sub-task description... Does this answer your questions?

  • repositoryName: a human readable name for the repository;
    • A base repository name is supplied via System property, and augmented with the tenant ID... i.e. "<baseRepoName>_<tenantId>" (e.g. FOLIO_diku)
  • baseURL: the base URL of the repository;
    • Supplied by System property
  • protocolVersion: the version of the OAI-PMH supported by the repository;
    • Hardcoded
  • earliestDatestamp: a UTCdatetime that is the guaranteed lower limit of all datestamps recording changes, modifications, or deletions in the repository. A repository must not use datestamps lower than the one specified by the content of the earliestDatestamp element. earliestDatestamp must be expressed at the finest granularity supported by the repository.
    • Hardcoded for now to epoch (seconds granularity)
  • deletedRecord: the manner in which the repository supports the notion of deleted records. Legitimate values are no ; transient ; persistent with meanings defined in the section on deletion.
    • Hardcoded to "no" for now
  • granularity: the finest harvesting granularity supported by the repository. The legitimate values are YYYY-MM-DD and YYYY-MM-DDThh:mm:ssZ with meanings as defined in ISO8601.
    • Hardcoded to YYYY-MM-DDThh:mm:ssZ for now
  • adminEmail: the e-mail address of an administrator of the repository.
    • Supplied via System property for now. will eventually be configurable in FOLIO.

compression and description elements can be skipped for now.
System properties should be read at startup (see edge apis for examples)

Comment by Piotr Kalashuk [ 16/Oct/18 ]

Thank you very much Craig for clarification!

Comment by Piotr Kalashuk [ 22/Oct/18 ]

Summary of the implementation:

  • Some configuration is defined in config.properties. Content at the moment is following:
    # Properties describing repository. Mainly are going to be used by Identify verb
    repository.name=FOLIO_OAI_Repository
    repository.baseURL=http://tbd.later.folio.org/oai
    repository.adminEmails=oai-pmh@folio.org
    
    # Jaxb settings
    jaxb.marshaller.enableValidation=true
    jaxb.marshaller.formattedOutput=false
    

    The default values can be overwritten by VM arguments e.g. -Drepository.name=Specific_FOLIO_OAI-PMH_Repository

  • The value of repository.baseURL will be used in all OAI-PMH responses as value of OAI-PMH/request element e.g.
    <OAI-PMH xsi:schemaLocation="http://www.openarchives.org/OAI/2.0/ http://www.openarchives.org/OAI/2.0/OAI-PMH.xsd" xmlns="http://www.openarchives.org/OAI/2.0/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
      ...
      <request verb="Identify">http://tbd.later.folio.org/oai</request>
      ...
    </OAI-PMH>
    
  • The repository.adminEmails property value might contain several emails which should be separated by comma
  • The response validation is enabled by default and can be disabled by passing -Djaxb.marshaller.enableValidation=false as VM argument

Regards,
Piotr

Comment by Piotr Kalashuk [ 22/Oct/18 ]

The News and Readme updates are available in PR #8.

Regards,
Piotr

Comment by Piotr Kalashuk [ 23/Oct/18 ]

All the changes are now in master. The output for the <host:port>/oai/repository_info with default configs is coming like (the output below is formatted to improve readability):

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<OAI-PMH xsi:schemaLocation="http://www.openarchives.org/OAI/2.0/ http://www.openarchives.org/OAI/2.0/OAI-PMH.xsd" xmlns="http://www.openarchives.org/OAI/2.0/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
    <responseDate>2018-10-23T07:00:34Z</responseDate>
    <request verb="Identify">http://tbd.later.folio.org/oai</request>
    <Identify>
        <repositoryName>FOLIO_OAI_Repository_diku</repositoryName>
        <baseURL>http://tbd.later.folio.org/oai</baseURL>
        <protocolVersion>2.0</protocolVersion>
        <adminEmail>oai-pmh@folio.org</adminEmail>
        <earliestDatestamp>1970-01-01T00:00:00Z</earliestDatestamp>
        <deletedRecord>no</deletedRecord>
        <granularity>YYYY-MM-DDThh:mm:ssZ</granularity>
    </Identify>
</OAI-PMH>

If the service is deployed with -Drepository.baseURL=http://some-cloud.folio.org/oai -Drepository.name=OverriddenRepoName -Drepository.adminEmails=oai-pmh-admin@folio.org,another-oai-pmh-admin@folio.org, the output is

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<OAI-PMH xsi:schemaLocation="http://www.openarchives.org/OAI/2.0/ http://www.openarchives.org/OAI/2.0/OAI-PMH.xsd" xmlns="http://www.openarchives.org/OAI/2.0/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
    <responseDate>2018-10-23T07:08:19Z</responseDate>
    <request verb="Identify">http://some-cloud.folio.org/oai</request>
    <Identify>
        <repositoryName>OverriddenRepoName_diku</repositoryName>
        <baseURL>http://some-cloud.folio.org/oai</baseURL>
        <protocolVersion>2.0</protocolVersion>
        <adminEmail>oai-pmh-admin@folio.org</adminEmail>
        <adminEmail>another-oai-pmh-admin@folio.org</adminEmail>
        <earliestDatestamp>1970-01-01T00:00:00Z</earliestDatestamp>
        <deletedRecord>no</deletedRecord>
        <granularity>YYYY-MM-DDThh:mm:ssZ</granularity>
    </Identify>
</OAI-PMH>

Regards,
Piotr

Comment by Ann-Marie Breaux (Inactive) [ 25/Oct/18 ]

Hkaplanian Former user Craig McNally This is marked In Review and showing up on the manual testing list, but I don't think there's anything we should be manually testing, right? Two possibilities: 1 Cate can change the In Review filter to exclude Thunderjet stuff (https://folio-org.atlassian.net/issues/?filter=10466). 2. we can flag them when we see them and alert you to close them. Let us know which you prefer.

Comment by Craig McNally [ 25/Oct/18 ]

Ann-Marie Breaux I think #1 makes sense. Here I think the intent was to get review from the PO (Hkaplanian).

Comment by Ann-Marie Breaux (Inactive) [ 25/Oct/18 ]

OK - I'll get Cate Boerema to update the filter

Generated at Fri Feb 09 00:13:36 UTC 2024 using Jira 1001.0.0-SNAPSHOT#100246-sha1:7a5c50119eb0633d306e14180817ddef5e80c75d.