Versions Compared

Key

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

...

  1. Triplestore (Fuseki or Sesame)
  2. Fedora 4 Repository
  3. JMS Event event listener/indexer

The triplestore and Fedora4 do not need to be aware of each other or of the jms-event-JMS listener. However, the event-listener needs to know the web-endpoints of both the triplestore and Fedora 4. It is therefore important that you start the three components on different ports. 
Instructions on how to start up and configure the three components follows:

...

You can deploy Fedora4 either by downloading the latest war file and dropping it into an application container (e.g. Tomcat7). Or you can clone the Git fcrepo4 project and run the fcrepo-webapp directly within the code base.
See the following pages for details on either approach:

3. JMS Event Indexer

You can deploy the jms-JMS event - listener/indexer by downloading the latest war file and dropping it into an application container (e.g. Tomcat7Tomcat 7). Or you can clone the Git fcrepo-jmsmessage-indexer-pluggableconsumer project and run the fcrepo-jmsmessage-indexerconsumer-webapp pluggable directly within the code base.It  Building the project from source will likely be make it easier to configure the jms-JMS event -indexer by building the application from sourcelistener/indexer.

You can specify the connection to either Fuseki or Sesame in the following configuration file.

  • By default, Fuseki is expected
  • To connect to Sesame instead, comment out the "queryBase", "updateBase", and "formUpdates" XML elements associated with Fuseki, and uncomment the corresponding Sesame XML elements in the configuration file mentioned above.

To configure the jms-event-JMS indexer to connect to the Fedora Repository, you can set the following system variables

  • -Dfcrepo.host=<defaults.to.localhost>
  • -Dfcrepo.port=<defaults.to.8080>

To configure the jms-event-JMS indexer to connect to the triplestore, you can set the following system variables

...

Below is an example of how to download, build, and start the jms-event-JMS indexer.

Code Block
$ git clone https://github.com/futuresfcrepo4/fcrepo-jmsmessage-indexer-pluggableconsumer.git
  
$ cd fcrepo-jmsmessage-indexer-pluggableconsumer
$ mvn install
$ cd fcrepo-jmsmessage-indexer-webappconsumer
$ mvn -Dfcrepo.host=localhost -Dfcrepo.port=8080 -Dfuseki.host=localhost -Dfuseki.port=3030 -Djetty.port=8082 jetty:run

If the Fedora Repository is be running at http://localhost:8080/rest/  – you can create, update and delete objects and datastreams resources using your browser, or using the REST API (see SPARQL Recipes ).  Each event will trigger the indexer and be synced to Fuseki (or Sesame), which you can access at  http://localhost:3030/  (if you have Fuseki running on its default port).

...

In some situations it is desirable to have multiple Fedora repositories all feeding into a single external triplestore. In order to accomplish this, we need to install and setup the three components (Triplestore, Fedora 4 Repository and JMS Event event listener/indexer) as follows:

  1. Follow the instructions above to install the triplestore (Fuseki or Sesame) in one machine and start it.

  2. Follow the instructions above to install two or more Fedora 4 Repositories in different machines and start them.

  3. Install JMS Event event listener/indexer (https://github.com/futuresfcrepo4/fcrepo-jmsmessage-indexer-pluggableconsumer) for each Fedora 4 repository installation and start the indexer with the following command:

    Code Block
    languagebash
    $ mvn -D jetty.port=9999 -Dfuseki.host=<triplestore.host.name> -Dfcrepo.host=<repository.host.name> jetty:run
  4. Notes

    • To make an object indexable in the triplestore, the object needs to include indexable mixin type: http://fedora.info/definitions/v4/indexing#indexable, which can be inserted through a SPARQL insert:

      Code Block
      INSERT {<> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://fedora.info/definitions/v4/indexing#indexable> }.
    • Start the triplestore first. If the triplestore is restarted, then the JMS Event event listener/indexer needs to be restarted, too.