3.13.2.1.1. JMS
The JMS remote commit provider can be configured by setting the openjpa.RemoteCommitProvider property to contain the appropriate configuration properties.
The JMS provider understands the following properties:
-
Topic: The topic that the remote commit provider should publish notifications to and subscribe to for notifications sent from other JVMs. Defaults totopic/OpenJPACommitProviderTopic -
TopicConnectionFactory: The JNDI name of ajakarta.jms.TopicConnectionFactoryfactory to use for finding topics. Defaults tojava:/ConnectionFactory. This setting may vary depending on the application server in use; consult the application server’s documentation for details of the default JNDI name for thejakarta.jms.TopicConnectionFactoryinstance. For example, under Weblogic, the JNDI name for the TopicConnectionFactory isjakarta.jms.TopicConnectionFactory. -
ExceptionReconnectAttempts: The number of times to attempt to reconnect if the JMS system notifies OpenJPA of a serious connection error. Defaults to 0, meaning OpenJPA will log the error but otherwise ignore it, hoping the connection is still valid. -
\*: All other configuration properties will be interpreted as settings to pass to the JNDIInitialContexton construction. For example, you might set thejava.naming.provider.urlproperty to the URL of the context provider.
To configure a factory to use the JMS provider, your properties might look like the following:
<property name="openjpa.RemoteCommitProvider"
value="jms(ExceptionReconnectAttempts=5)"/>
|
|
Because of the nature of JMS, it is important that you invoke |
|
|
The JMS provider sends events as |