Old Release

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

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Current »

Out of the box, Fedora is configured to publish its event messages to a JMS topic. While this is adequate for small-scale demo and testing usage, for production deployments it is recommended that you use a JMS queue instead. The primary advantage of queues over topics is that messages in a queue are persisted until they are read by a consumer, whereas messages in a topic can be more ephemeral.

To enable the JMS queue, and disable the JMS topic, edit the JMS messaging section of your Spring configuration file to look like this:

Use JMS Queue
<!--   JMS Topic -->
<!-- disabled in favor of the queue
<bean class="org.fcrepo.jms.JMSTopicPublisher">
  <constructor-arg value="fedora"/>
</bean>
-->

<!-- JMS Queue -->
<bean class="org.fcrepo.jms.JMSQueuePublisher">
  <constructor-arg value="fedora"/>
</bean>

 

Note that although queues persist their messages until they are read by a consumer, once any consumer reads a message, that message is dequeued. Therefore, if you need multiple consumers to be able to read the same message in parallel, you will need to configure a way to broadcast (i.e., copy) the message from one input queue to multiple output queues.

One implementation of this pattern is Amherst College's acrepo-connector-broadcast Camel route, part of their suite of repository extension services.



  • No labels