Hermes v1.13, OpenJMS 0.7.7, not getting any joy...

Using Hermes with OpenJMS

Hermes v1.13, OpenJMS 0.7.7, not getting any joy...

Postby jessex » Thu Jan 22, 2009 10:45 am

Hello, I've spent a while trying to get Hermes working with OpenJMS (and yes, that included reading prior posts to this forum!)

I have created a provider for OpenJMS by adding the relevant libraries. I have tried creating a session two different ways, once with the RMI protocol and once with tcp. With RMI, all I get is an error message:

javax.jms.JMSException: Could not create InitialContext: Failed to get registry service for URL: rmi://localhost:1099
at hermes.JNDIContextFactory.createContext(JNDIContextFactory.java:282)
at hermes.JNDIConnectionFactory.createConnection(JNDIConnectionFactory.java:80)
at hermes.impl.jms.ConnectionManagerSupport.createConnection(ConnectionManagerSupport.java:122)
(....etc....)

Which is odd because my application connects to the same OpenJMS server over RMI quite happily (I created the provider url by cut and paste from the application)

The relevant section of my config file is here:

<factory classpathId="OpenJMSGroup">
<provider className="hermes.JNDIQueueConnectionFactory">
<properties>
<property name="binding" value="JmsQueueConnectionFactory "/>
<property name="initialContextFactory" value="org.exolab.jms.jndi.InitialContextFactory"/>
<property name="providerURL" value="rmi://localhost:1099"/>
</properties>
</provider>
<connection clientID="" connectionPerThread="false">
<session audit="false" id="JonSess" reconnects="0" transacted="true" useConsumerForQueueBrowse="false"/>
</connection>
(destinations removed for brevity)
<extension className="hermes.ext.DefaultHermesAdminFactory">
<properties/>
</extension>
</factory>

If I try to use the tcp protocol I get a little further. I am then able to right-click on the session to discover the queues on the server. However clicking on these queues always produces the same error message:

javax.jms.JMSException: JmsQueueConnectionFactory
at hermes.JNDIConnectionFactory.createConnection(JNDIConnectionFactory.java:85)
at hermes.impl.jms.ConnectionManagerSupport.createConnection(ConnectionManagerSupport.java:122)

Where the text of the exception ('JmsQueueConnectionFactory') always corresponds to whatever I have written in the 'binding' property for the connection factory. I've tried many different values for this field... Again, here's the relevant bit from the hermes config file:

<factory classpathId="OpenJMSGroup">
<provider className="hermes.JNDIQueueConnectionFactory">
<properties>
<property name="binding" value="JmsQueueConnectionFactory "/>
<property name="initialContextFactory" value="org.exolab.jms.jndi.InitialContextFactory"/>
<property name="providerURL" value="tcp://localhost:3035"/>
</properties>
</provider>
<connection clientID="" connectionPerThread="false">
<session audit="false" id="JonSess" reconnects="0" transacted="true" useConsumerForQueueBrowse="false"/>
</connection>
<extension className="hermes.ext.DefaultHermesAdminFactory">
<properties/>
</extension>
</factory>

Am I missing something obvious?
jessex
 
Posts: 1
Joined: Thu Jan 22, 2009 9:59 am

Re: Hermes v1.13, OpenJMS 0.7.7, not getting any joy...

Postby Colin » Fri Apr 03, 2009 2:05 pm

No I see nothing obiously wrong here.

Are you still getting the same error? It may be worth looking down the stack trace into the OpenJMS code and see where the error comes from as its not very descriptive...

Regards,

Colin.
Colin
Site Admin
 
Posts: 835
Joined: Sun Sep 19, 2004 4:49 pm
Location: London, UK


Return to OpenJMS

Who is online

Users browsing this forum: No registered users and 1 guest