Can you check which versions of proton-j are on the classpath? A
likely related report came up a couple of weeks ago, where someone was
trying to use the JMS client and another client together in the same
VM, but the latter embedded a fairly old version of proton-j which
lacks some newer methods the JMS client is using. That caused
behaviour similar to what you describe if the older proton-j version
came first on the classpath. I haven't yet had a look into where it is
misbehaving inside the client to try and improve the behaviour when it
does. The 0.10.0 release actually uses that version of the broker in
some of its tests, for what its worth.

Robbie

On 19 July 2016 at 09:17, DraCzech <dracz...@gmail.com> wrote:
> Hi, I'm trying to make work following components to work together:
>
> - Apache Active MQ 5.13.3
> - Qpid JMS Client 0.10.0 (tested on 0.9.0 as well)
>
> The goal is to connect to MS  Azure IoT Hub
> <https://azure.microsoft.com/en-us/services/iot-hub/>   using the Qpid JMS
> client while running ActiveMQ for legacy reasons (mainly message
> persistence). Both components are used as maven dependencies of my bundle.
> This bundle creates and maintains bridges between remote server and local
> client. So it is responsible for the whole communication starting/closing
> stuff.
>
> When the bridge is created I pass the JmsConnectionFactory instance as
> QueueConnectionFactory to the bridge. Later I want to open the connection
> and I face the following issue:
>
> *The connect method on the connection just hangs when called.* And I suppose
> it is connected to the clientID problem.
>
> If the clientID property is set on the JmsConnectionFactory, the Connection
> class cannot be instantiated, because the process hangs in the
> configureConnection() method.
>
> On the other hand, when the clientID is set to the Connection instance
> directly, JmsQueueConnection instance can be created. But the process hangs
> once setClientId() is called on the instance. (It leads to the connect()
> method of JmsConnection and that leads to a freeze on a synced future.)
>
> If no ID is assigned the process goes seemingly fine. But the proces hangs
> in the Connection.start() method which leads to connect() method call on
> JmsConnection and then is synced on a lock and gets never unlocked again.
>
> And lastly if none of those methods is called by my code, the process hangs
> later anyway, because of the connect() method being called when Session is
> instantiated on the connection or so...
>
> This is the part of code where it gets stuck on the *request.sync()* call:
>
> void createResource(JmsResource resource, ProviderSynchronization
> synchronization) throws JMSException {
>         checkClosedOrFailed();
>
>         try {
>                 ProviderFuture request = new ProviderFuture(synchronization);
>                 requests.put(request, request);
>                 try {
>                         provider.create(resource, request);
>                         request.sync();
>                 } finally {
>                         requests.remove(request);
>                 }
>         } catch (Exception ex) {
>                 throw JmsExceptionSupport.create(ex);
>         }
> }
>
> I'd like to point out that the communication works fine if I use only Qpid
> JMS client and proton-j to connect to the IoT Hub in a separate project
> using the same credentials.
>
> Thanks for any help!
>
>
>
>
> --
> View this message in context: 
> http://qpid.2158936.n2.nabble.com/Cannot-conect-while-using-ActiveMQ-with-Qpid-JMS-client-tp7647859.html
> Sent from the Apache Qpid users mailing list archive at Nabble.com.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@qpid.apache.org
> For additional commands, e-mail: users-h...@qpid.apache.org
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@qpid.apache.org
For additional commands, e-mail: users-h...@qpid.apache.org

Reply via email to