On 11 May 2017 at 16:35, Robbie Gemmell <[email protected]> wrote:
> On 11 May 2017 at 16:27, Robbie Gemmell <[email protected]> wrote:
>> On 11 May 2017 at 16:13, jeunii <[email protected]> wrote:
>>> Thanks for your reply.
>>>
>>> Actually it is picking up the config using the below config ::
>>>
>>>     System.setProperty("javax.net.ssl.trustStore",
>>> "C:/Users/xxxxx/qpid.jks");
>>>     System.setProperty("javax.net.ssl.trustStorePassword", "test123");
>>>
>>> If I remove these lines, the code will complain above a missing trustStore
>>> file.
>>
>> Ok, perhaps it hasnt imported the classes yet due to using JNDI to
>> instantiate it.
>>
>>> I tried using the latest library for Qpid but get the below ERROR ::
>>>
>>> Exception in thread "main" java.lang.NoClassDefFoundError:
>>> javax/jms/JMSContext
>>>         at
>>> org.apache.qpid.jms.jndi.JmsInitialContextFactory.getConnectionFactoryDefaults(JmsInitialContextFactory.java:202)
>>>         at
>>> org.apache.qpid.jms.jndi.JmsInitialContextFactory.createConnectionFactories(JmsInitialContextFactory.java:133)
>>>         at
>>> org.apache.qpid.jms.jndi.JmsInitialContextFactory.getInitialContext(JmsInitialContextFactory.java:103)
>>>         at 
>>> javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:684)
>>>         at 
>>> javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:313)
>>>         at javax.naming.InitialContext.init(InitialContext.java:244)
>>>         at javax.naming.InitialContext.<init>(InitialContext.java:216)
>>>         at AMQPQPIDTest.runTest(AMQPQPIDTest.java:27)
>>>         at AMQPQPIDTest.main(AMQPQPIDTest.java:20)
>>> Caused by: java.lang.ClassNotFoundException: javax.jms.JMSContext
>>>         at java.net.URLClassLoader.findClass(URLClassLoader.java:381)
>>>         at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
>>>         at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:331)
>>>         at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
>>>         ... 9 more
>>>
>>
>> Thats complaining about JMSContext, an interface from JMS 2.0, which
>> the current client versions (0.20.0) implement/require rather than
>> only JMS 1.1 like the older releases.
>
> That was meant to be '0.20.0+', with the actual current version being
> 0.22.0 (though 0.23.0 is likely to be coming very soon)
>
>>
>> If the above SSL config was already being picked up however, it would
>> suggest you have some other problem. I can't think any anything else
>> form the limited information available, perhaps you can debug the
>> failure (either via logging, protocol tracing, wireshark, etc) and get
>> a better idea whats going on.
>>
>> Robbie

Tim and I have posted some comments on your various StackOverflow
posts, but for the interests of those reading here later I thought I'd
post a roundup mail.

Your StackOverflow posts mention RabbitMQ and ActiveMQ. It isn't clear
which you are using, though I think it may be the former.

As Tim mentioned, you would at minimum also need to ensure the
RabbitMQ brokers experimental AMQP 1.0 plugin was loaded, which you
didn't mention doing. However, in this case it might not make much
difference. I didn't have much success using the JMS client or some
other AMQP 1.0 clients against RabbitMQ previously due to an issue I
reported which stops them in their tracks when creating consumers and
producers: https://github.com/rabbitmq/rabbitmq-amqp1.0/issues/34

Turning up the clients logging might give some more trace/debug
information. Both the 'regular logging', and 'protocol trace logging'
(if it even gets that far) might be useful. See
http://qpid.apache.org/releases/qpid-jms-0.22.0/docs/index.html#logging
for more details.

To the stacktrace here, where it seems the TCP connection is being
cut, the server logs could also perhaps be useful in giving a reason.

Its unclear how far the connection gets, but if the server is
RabbitMQ, one potential explanation might also be:
https://github.com/rabbitmq/rabbitmq-amqp1.0/issues/47

Your mentioned researching things before deciding to use RabbitMQ,
which sounds like you aren't tied to an existing server solution? If
so, for other servers that support AMQP 1.0 and the JMS client is
routinely used against, you could try ActiveMQ, ActiveMQ Artemis, Qpid
for Java broker, Qpid C++ broker, and Qpid Dispatch router (does not
work on Windows, which you seem to be using), amongst others.

Robbie

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to