Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Building fcrepo-oaiprovider

  1.  Obtain and build the fcrepo-oaiprovider source code:

 

 

 

  1. Code Block
    languagetext
        git clone https://github.com/fcrepo4-labs/fcrepo4-oaiprovider.git
        cd fcrepo4-oaiprovider
        mvn package

...

 

...

  1.  Move the generated JAR to the Tomcat lib folder:

    Code Block
    languagetext
        cp target/fcrepo4-oaiprovider-4.0.0-beta-04-SNAPSHOT.jar <CATALINA_HOME>/webapps/<fcrepo>/WEB-INF/lib

...

...

  1.  Copy the oai.xml file to the fcrepo config directory:

    Code Block
        cp fcrepo4-oaiprovider/src/main/resources/spring/oai.xml /<CATALINA_HOME>/webapps/<fcrepo>/WEB-INF/classes/spring/

...

...

  1. Add the import to fcrepo's master.xml file:

...

  1.   - Edit <CATALINA_HOME>/webapps/<fcrepo>/WEB-INF/classes/spring/master.xml

...

  1.    - Add '<import resource="classpath:/spring/oai.xml"/>' after the other <import> declarations

...

  1. Make sure the OAI namespace is defined as a Compact Node Definition Type. Add:

...

  1.  <oai =

...

  1. 'http://www.openarchives.org/OAI/2.0/'

...

  1. > to fcrepo-kernel-impl/src/main/resources/fedora-node-types.cnd in the main core and rebuilt, but you may have to find another way to add it. See Here

...

...

  1. Restart Tomcat. Go to http://localhost:8080/<fcrepo>/rest/oai?verb=Identify. If it all worked, you should see XML that defines the default configuration for the OAI-PMH provider.

Common errors are either the OAI-PMH provider generating 4xx HTTP error codes or producing the default values (see below). The 4xx HTTP Error codes are a manifestation that the namespace having not been defined (Step 4b above), so make sure the OAI compact node definition has been added to the fedora-node-types.cnd file or however you have found to add the definition is correct.The default values appearing instead of properties you have defined would mean the properties are not available or defined incorrectly. 

Configuring the OAI-PMH provider

...