You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@qpid.apache.org by Kyle <kh...@gmail.com> on 2013/05/30 09:19:03 UTC

Qpid Proton Unsolved Address Exception for Azure Service Bus

Hi,

I am using Java Qpid Proton to exchange messages with Windows Azure Service
Bus and I got the error of UnresolvedAddressException.

Has anyone had experience with  with Windows Azure could help me?

The code I used as the below.
..
messenger.start();

MessageFactoryImpl messageFactoryImpl = new MessageFactoryImpl();
Message msg = messageFactoryImpl.createMessage();

msg.setAddress("amqps://owner:password@namespace.servicebus.windows.net:5671/queue");

messenger.put(msg);
messenger.send();
..

Thanks.



--
View this message in context: http://qpid.2158936.n2.nabble.com/Qpid-Proton-Unsolved-Address-Exception-for-Azure-Service-Bus-tp7593622.html
Sent from the Apache Qpid users mailing list archive at Nabble.com.

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


Re: Qpid Proton Unsolved Address Exception for Azure Service Bus

Posted by Gordon Sim <gs...@redhat.com>.
On 05/31/2013 03:07 AM, Kyle wrote:
> Now It seems to work because no exception was occurred. But nothing was sent
> to queue on windows azure servicebus.

Probably best to turn up the logging to see what was sent (set 
proton.trace.level to FINE) or use wireshark.

> Once I tried without the 'owner:password@', the messenger was hanged
> forever.

That sounds like a bug of some sort. I would expect an authentication error.

> One thing I guessed is that constructor of Proton/Messenger requires a port
> number as one of its signatures whereas ConnectionURL of JMS doesn't, the
> difference of implementations between them is the root cause.

Again, that sounds like a bug, but a strange one as the port should be 
implied by the scheme if not specified. (I assume you mean the message 
address rather than the constructor of the Messenger instance).




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


Re: Qpid Proton Unsolved Address Exception for Azure Service Bus

Posted by Kyle <kh...@gmail.com>.
Now It seems to work because no exception was occurred. But nothing was sent
to queue on windows azure servicebus.

Once I tried without the 'owner:password@', the messenger was hanged
forever.

One thing I guessed is that constructor of Proton/Messenger requires a port
number as one of its signatures whereas ConnectionURL of JMS doesn't, the
difference of implementations between them is the root cause.



--
View this message in context: http://qpid.2158936.n2.nabble.com/Qpid-Proton-Unsolved-Address-Exception-for-Azure-Service-Bus-tp7593622p7593649.html
Sent from the Apache Qpid users mailing list archive at Nabble.com.

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


Re: Qpid Proton Unsolved Address Exception for Azure Service Bus

Posted by Gordon Sim <gs...@redhat.com>.
On 05/30/2013 12:10 PM, Kyle wrote:
> I cant use ping namespace.servicebus.windows.net
>
> But when I have tried the same hostname "namespace.servicebus.windows.net"
> with JMS qpid 0.20. It works finely.
>
> JNDI  looks
>
> ..
> #connectionfactory.localhost = amqps://owner:password @
> namespace.servicebus.windows.net
> ..
>
> I don't know what is different between connectionfactory of JMS and hostname
> of connection in Java qpid proton.


Have you tried without the 'owner:password@'? It's possible that is 
tripping the java messenger up.

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


Re: Qpid Proton Unsolved Address Exception for Azure Service Bus

Posted by Rob Godfrey <ro...@gmail.com>.
Do you have the full stack trace of the exception you are getting from
Proton/Messenger?

thanks,
Rob


On 30 May 2013 13:10, Kyle <kh...@gmail.com> wrote:

> I cant use ping namespace.servicebus.windows.net
>
> But when I have tried the same hostname "namespace.servicebus.windows.net"
> with JMS qpid 0.20. It works finely.
>
> JNDI  looks
>
> ..
> #connectionfactory.localhost = amqps://owner:password @
> namespace.servicebus.windows.net
> ..
>
> I don't know what is different between connectionfactory of JMS and
> hostname
> of connection in Java qpid proton.
>
>
>
> --
> View this message in context:
> http://qpid.2158936.n2.nabble.com/Qpid-Proton-Unsolved-Address-Exception-for-Azure-Service-Bus-tp7593622p7593627.html
> Sent from the Apache Qpid users mailing list archive at Nabble.com.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@qpid.apache.org
> For additional commands, e-mail: users-help@qpid.apache.org
>
>

Re: Qpid Proton Unsolved Address Exception for Azure Service Bus

Posted by Kyle <kh...@gmail.com>.
I cant use ping namespace.servicebus.windows.net

But when I have tried the same hostname "namespace.servicebus.windows.net"
with JMS qpid 0.20. It works finely.

JNDI  looks

..
#connectionfactory.localhost = amqps://owner:password @
namespace.servicebus.windows.net
..

I don't know what is different between connectionfactory of JMS and hostname
of connection in Java qpid proton.



--
View this message in context: http://qpid.2158936.n2.nabble.com/Qpid-Proton-Unsolved-Address-Exception-for-Azure-Service-Bus-tp7593622p7593627.html
Sent from the Apache Qpid users mailing list archive at Nabble.com.

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


Re: Qpid Proton Unsolved Address Exception for Azure Service Bus

Posted by Gordon Sim <gs...@redhat.com>.
On 05/30/2013 09:31 AM, Khanh Sy Bui wrote:
> I have looked around in Java messenger code, I think it handled amqps
> already. Its use looks below.
>
> ...
> String certificateFile = "C:/ssl/crt.pem";
> String privateKeyFile = "C:/ssl/key.pem";
> String privateKeyPassword = "password";
> EngineFactoryImpl engineFactoryImpl = new EngineFactoryImpl();
> ProtonJSslDomain createSslDomain = engineFactoryImpl.createSslDomain();
> createSslDomain.setCredentials(certificateFile, privateKeyFile,
> privateKeyPassword);
> createSslDomain.setPeerAuthentication(VerifyMode.ANONYMOUS_PEER);
> Messenger mng = new MessengerImpl(java.util.UUID.randomUUID().toString(),
> engineFactoryImpl, new DriverFactoryImpl(), new MessageFactoryImpl());

I stand corrected! Sorry for the false information. I do indeed see some 
ssl handshake sniffing functionality in the codebase now.

> But it does not help to make connected with Azure Service Bus

Have you tried resolving the hostname?


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


Re: Qpid Proton Unsolved Address Exception for Azure Service Bus

Posted by Khanh Sy Bui <kh...@gmail.com>.
I have looked around in Java messenger code, I think it handled amqps
already. Its use looks below.

...
String certificateFile = "C:/ssl/crt.pem";
String privateKeyFile = "C:/ssl/key.pem";
String privateKeyPassword = "password";
EngineFactoryImpl engineFactoryImpl = new EngineFactoryImpl();
ProtonJSslDomain createSslDomain = engineFactoryImpl.createSslDomain();
createSslDomain.setCredentials(certificateFile, privateKeyFile,
privateKeyPassword);
createSslDomain.setPeerAuthentication(VerifyMode.ANONYMOUS_PEER);
Messenger mng = new MessengerImpl(java.util.UUID.randomUUID().toString(),
engineFactoryImpl, new DriverFactoryImpl(), new MessageFactoryImpl());

...

But it does not help to make connected with Azure Service Bus



On 30 May 2013 15:10, Gordon Sim <gs...@redhat.com> wrote:

> On 05/30/2013 08:19 AM, Kyle wrote:
>
>> Hi,
>>
>> I am using Java Qpid Proton to exchange messages with Windows Azure
>> Service
>> Bus and I got the error of UnresolvedAddressException.
>>
>> Has anyone had experience with  with Windows Azure could help me?
>>
>> The code I used as the below.
>> ..
>> messenger.start();
>>
>> MessageFactoryImpl messageFactoryImpl = new MessageFactoryImpl();
>> Message msg = messageFactoryImpl.**createMessage();
>>
>> msg.setAddress("amqps://owner:**password@namespace.servicebus.**
>> windows.net:5671/queue<http://owner:password@namespace.servicebus.windows.net:5671/queue>
>> ");
>>
>
> I have no experience with Azure, but the exception would suggest that
> namespace.servicebus.windows.**net<http://namespace.servicebus.windows.net>could not be resolved. Have you checked whether that is the case (e.g. with
> nslookup or by pinging or telnetting)?
>
> One other point is that I don't believe the Java messenger handles 'amqps'
> yet, i.e. it does not enable SSL. I would expect that to result in
> different errors/exceptions though.
>
>
>
>> messenger.put(msg);
>> messenger.send();
>> ..
>>
>> Thanks.
>>
>>
>>
>> --
>> View this message in context: http://qpid.2158936.n2.nabble.**
>> com/Qpid-Proton-Unsolved-**Address-Exception-for-Azure-**
>> Service-Bus-tp7593622.html<http://qpid.2158936.n2.nabble.com/Qpid-Proton-Unsolved-Address-Exception-for-Azure-Service-Bus-tp7593622.html>
>> Sent from the Apache Qpid users mailing list archive at Nabble.com.
>>
>> ------------------------------**------------------------------**---------
>> To unsubscribe, e-mail: users-unsubscribe@qpid.apache.**org<us...@qpid.apache.org>
>> For additional commands, e-mail: users-help@qpid.apache.org
>>
>>
>
> ------------------------------**------------------------------**---------
> To unsubscribe, e-mail: users-unsubscribe@qpid.apache.**org<us...@qpid.apache.org>
> For additional commands, e-mail: users-help@qpid.apache.org
>
>


-- 
Sincerely,

Khanh S. Bui

Re: Qpid Proton Unsolved Address Exception for Azure Service Bus

Posted by Gordon Sim <gs...@redhat.com>.
On 05/30/2013 08:19 AM, Kyle wrote:
> Hi,
>
> I am using Java Qpid Proton to exchange messages with Windows Azure Service
> Bus and I got the error of UnresolvedAddressException.
>
> Has anyone had experience with  with Windows Azure could help me?
>
> The code I used as the below.
> ..
> messenger.start();
>
> MessageFactoryImpl messageFactoryImpl = new MessageFactoryImpl();
> Message msg = messageFactoryImpl.createMessage();
>
> msg.setAddress("amqps://owner:password@namespace.servicebus.windows.net:5671/queue");

I have no experience with Azure, but the exception would suggest that 
namespace.servicebus.windows.net could not be resolved. Have you checked 
whether that is the case (e.g. with nslookup or by pinging or telnetting)?

One other point is that I don't believe the Java messenger handles 
'amqps' yet, i.e. it does not enable SSL. I would expect that to result 
in different errors/exceptions though.

>
> messenger.put(msg);
> messenger.send();
> ..
>
> Thanks.
>
>
>
> --
> View this message in context: http://qpid.2158936.n2.nabble.com/Qpid-Proton-Unsolved-Address-Exception-for-Azure-Service-Bus-tp7593622.html
> Sent from the Apache Qpid users mailing list archive at Nabble.com.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@qpid.apache.org
> For additional commands, e-mail: users-help@qpid.apache.org
>


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