Old Release

This documentation covers an old version of Fedora. Looking for another version? See all documentation.

The JcrXmlPersistenceIndexer listens to the repository generated JMS events and persists metadata in JCR/XML format to the file system. It implements the org.fcrepo.indexer.Indexer interface for the indexing functionalities, which consists of the methods to handle new/updated records and deleted records.

JCR/XML is a native format supported by Modeshape for backup and recovery. In the case of system failure that we need to recover the repository or share the metadata with other organizations, the persisted JCR/XML files serve this purpose.

The JCR/XML files are stored level by level under the configured directory fcrepo.jcrxml.storage (default fcrepo4-jcrxml), one folder for metadata and sub-containers under a Modeshape JCR container. At this time, the persisted JCR/XML files contains no binary values.

Configuration

The indexer is configured using Spring that can be done with Java bean setter methods.  Here is a sample configuration fragment showing how to configure and use the JcrXmlPersistenceIndexer:

  <!-- jcr/xml persistence Indexer -->
  <bean id="jcrXmlPersist" class="org.fcrepo.indexer.persistence.JcrXmlPersistenceIndexer">
    <constructor-arg value="${fcrepo.jcrxml.storage:fcrepo4-jcrxml}" />
  </bean>
 
  <!-- Message Driven POJO (MDP) that manages individual indexers -->
  <bean id="indexerGroup" class="org.fcrepo.indexer.IndexerGroup">
    <constructor-arg name="indexers">
      <set>
        ...
        <ref bean="jcrXmlPersist"/>
        ...
      </set>
    </constructor-arg>
    ...
  </bean>
  • No labels