You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@qpid.apache.org by Brant Boehmann <br...@gmail.com> on 2009/12/09 05:27:10 UTC

C++ broker, java client

I have a qpid C++ broker, and I'm trying to learn how to utilize the java
client to publish and receive messages via JMS.
When I try to connect with the url from the
example(connectionfactory.qpidConnectionfactory =
amqp://guest:guest@clientid/test?brokerlist='tcp://localhost:5672')

I get the stack trace at the bottom of the message indication authentication
failure. I'm told the qpid broker I'm connecting to has no ACL enabled, and
there is python code working which does not utilize a username and password
when creating a connection:

...
sock = connect(self.host, self.port)
...
self.conn      = Connection(sock=sock)
...

If I attempt to use a simpler url of the form
amqp:///test?brokerlist='localhost'

I get the following message:

WARNING: Unable to createFactories:User information not found on url between
indicies 7 and 1
amqp:///test?brokerlist='localhost'
       ^
javax.naming.NameNotFoundException: qpidConnectionfactory




How do I enter no username/password in the Connection URL for java?
What specifically is the clientid & virtualhost in the Connection URL as I
don't see an equivalent in the python examples?
Please help me get connected. I'm currently just using the JMS pubsub
samples from svn.


-------------STACK TRACE___________________________________
Dec 8, 2009 10:50:54 PM
org.apache.qpid.jndi.PropertiesFileInitialContextFactory getInitialContext
INFO: No Provider URL specified.
Dec 8, 2009 10:50:54 PM org.apache.qpid.jms.failover.FailoverSingleServer
getNextBrokerDetails
INFO: No delay between connect retries, use
tcp://host:port?connectdelay='value' to enable.
Dec 8, 2009 10:50:54 PM org.apache.qpid.client.AMQConnection <init>
INFO:
Connection:amqp://guest:********@bb/test?brokerlist='tcp://localhost:5672'
Dec 8, 2009 10:50:54 PM org.apache.qpid.client.AMQConnection <init>
INFO: Unable to connect to broker at tcp://localhost:5672
org.apache.qpid.AMQException: cannot connect to broker [error code 504:
channel error]
        at
org.apache.qpid.client.AMQConnectionDelegate_0_10.makeBrokerConnection(AMQConnectionDelegate_0_10.java:172)
        at
org.apache.qpid.client.AMQConnection.makeBrokerConnection(AMQConnection.java:728)
        at
org.apache.qpid.client.AMQConnection.<init>(AMQConnection.java:520)
        at
org.apache.qpid.client.AMQConnectionFactory.createConnection(AMQConnectionFactory.java:276)
        at Listener.runTest(Listener.java:75)
        at Listener.main(Listener.java:45)
Caused by: org.apache.qpid.transport.ConnectionException: connection-forced:
Authentication failed
        at
org.apache.qpid.transport.ConnectionException.rethrow(ConnectionException.java:67)
        at org.apache.qpid.transport.Connection.connect(Connection.java:202)
        at
org.apache.qpid.client.AMQConnectionDelegate_0_10.makeBrokerConnection(AMQConnectionDelegate_0_10.java:161)
        ... 5 more
Caused by: org.apache.qpid.transport.ConnectionException: connection-forced:
Authentication failed
        at
org.apache.qpid.transport.Connection.closeCode(Connection.java:419)
        at
org.apache.qpid.transport.ConnectionDelegate.connectionClose(ConnectionDelegate.java:76)
        at
org.apache.qpid.transport.ConnectionDelegate.connectionClose(ConnectionDelegate.java:40)
        at
org.apache.qpid.transport.ConnectionClose.dispatch(ConnectionClose.java:91)
        at
org.apache.qpid.transport.ConnectionDelegate.control(ConnectionDelegate.java:49)
        at
org.apache.qpid.transport.ConnectionDelegate.control(ConnectionDelegate.java:40)
        at org.apache.qpid.transport.Method.delegate(Method.java:151)
        at
org.apache.qpid.transport.Connection.received(Connection.java:285)
        at org.apache.qpid.transport.Connection.received(Connection.java:52)
        at
org.apache.qpid.transport.network.Assembler.emit(Assembler.java:98)
        at
org.apache.qpid.transport.network.Assembler.assemble(Assembler.java:184)
        at
org.apache.qpid.transport.network.Assembler.frame(Assembler.java:132)
        at org.apache.qpid.transport.network.Frame.delegate(Frame.java:133)
        at
org.apache.qpid.transport.network.Assembler.received(Assembler.java:103)
        at
org.apache.qpid.transport.network.Assembler.received(Assembler.java:48)
        at
org.apache.qpid.transport.network.InputHandler.next(InputHandler.java:186)
        at
org.apache.qpid.transport.network.InputHandler.received(InputHandler.java:103)
        at
org.apache.qpid.transport.network.InputHandler.received(InputHandler.java:42)
        at
org.apache.qpid.transport.network.io.IoReceiver.run(IoReceiver.java:128)
        at java.lang.Thread.run(Thread.java:619)
Dec 8, 2009 10:50:54 PM org.apache.qpid.jms.failover.FailoverSingleServer
getNextBrokerDetails
INFO: No delay between connect retries, use
tcp://host:port?connectdelay='value' to enable.

Re: C++ broker, java client

Posted by Glen Marchesani <gl...@model3.net>.
I added that and didn't see any noticable difference.  My test was a single
producer that produces messages as fast as it can and one consumer in
pubsub.  I changed my connect/session creation from this

        self.conn      = Connection(sock=sock)
        self.conn.start(timeout=10)
        self.session   = self.conn.session(str(uuid4()))

to this

        self.conn      = Connection(sock=sock)
        self.conn.start(timeout=10)
        self.session   = self.conn.session(str(uuid4()))
        self.session..auto_sync = False


Perhaps I am missing something else where...


On Thu, Dec 10, 2009 at 2:22 AM, Gordon Sim <gs...@redhat.com> wrote:

> On 12/10/2009 05:37 AM, Glen Marchesani wrote:
>
>> One interesting note is the performance of our python client was around
>> 1000
>> msgs/second.  With the java client we are seeing something closer to
>> 10,000
>> msgs/second.
>>
>
> Were you using synchronous transfer with python? That is the default for
> python; you can switch to asynchronous by setting session.auto_sync = False
> and then explicitly sync() as needed.
>
>
> ---------------------------------------------------------------------
> Apache Qpid - AMQP Messaging Implementation
> Project:      http://qpid.apache.org
> Use/Interact: mailto:users-subscribe@qpid.apache.org
>
>

Re: C++ broker, java client

Posted by Gordon Sim <gs...@redhat.com>.
On 12/10/2009 05:37 AM, Glen Marchesani wrote:
> One interesting note is the performance of our python client was around 1000
> msgs/second.  With the java client we are seeing something closer to 10,000
> msgs/second.

Were you using synchronous transfer with python? That is the default for 
python; you can switch to asynchronous by setting session.auto_sync = 
False and then explicitly sync() as needed.

---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project:      http://qpid.apache.org
Use/Interact: mailto:users-subscribe@qpid.apache.org


Re: C++ broker, java client

Posted by Rajith Attapattu <ra...@gmail.com>.
Hey Glen,

I am glad it worked out for you.
If you have any further JMS/Java related questions please feel free to ask.

Rajith

On Thu, Dec 10, 2009 at 12:37 AM, Glen Marchesani <gl...@model3.net> wrote:
> Hi Rajith,
> Thanks for your help and quick responses.  It looks like our issue was
> related to a bad build of qpid.  My apologies for this.  In short when I ran
> it with the "qpidd -t" option.  I had to do it on a different machine and
> when I ran our example java code it worked (with the url of
> amqp://guest:guest@clientid/test?brokerlist='tcp://172.16.1.52:5672').  The
> issue was the qpidd server we were originally using as I went back to that
> and saw the issue again.
>
> We were running qpid C++ 0.5 daemon.
>
> One interesting note is the performance of our python client was around 1000
> msgs/second.  With the java client we are seeing something closer to 10,000
> msgs/second.  Very informal tests but enough that I thought it worth
> mentioning.
>
>
>
> On Wed, Dec 9, 2009 at 9:59 PM, Rajith Attapattu <ra...@gmail.com> wrote:
>
>> On Wed, Dec 9, 2009 at 8:57 PM, Brant Boehmann <br...@gmail.com>
>> wrote:
>> > I think Glen will be running your test soon, but I may have stumbled
>> across
>> > the issue while digging through qpid code.
>> >
>> > The docs say a url of the form: It
>> >
>> >
>> amqp://[<user>:<pass>@][<clientid>]<virtualhost>[?<option>='<value>'[&<option>='<value>']]
>> >
>> > It then goes on to give examples like:
>> >
>> > amqp:///test?brokerlist='localhost'
>> > amqp:///test?brokerlist='tcp://anotherhost:5684?retries='10''
>> > amqp://guest:guest@
>> /test?brokerlist='vm://:1;vm://:2'&failover='roundrobin'
>> > amqp://guest:guest@
>> /test?brokerlist='vm://:1;vm://:2'&failover='roundrobin?cyclecount='20''
>> > amqp://guest:guest@client
>> /test?brokerlist='tcp://localhost;tcp://redundant-server:5673?ssl='true''&failover='roundrobin'
>> > amqp://guest:guest@/test?brokerlist='vm://:1'&failover='nofailover'
>> >
>> >
>> >
>> > This implies that the user info (ie guest:guest) are not required.
>>
>> Yes the documentation does imply that, all though the code doesn't reflect
>> it.
>> I sincerely apologize for this mistake.
>> One of the biggest issues we have right now is that our documentation
>> is sometimes out of sync with the code.
>> We are trying to address this as a matter of priority.
>>
>> All though the code treats the user_info as mandatory sometimes it
>> doesn't make sense especially when using mechanisms like anon or
>> kerberos.
>> So IMO the documentation is correct and the username/password should
>> be optional.
>> However looking at the svn history, it seems that the user info has
>> always been treated mandatory.
>>
>> We should either fix the code or the documentation.
>> Would you like to create a JIRA for this?
>> Again sorry for the inconvenience.
>>
>> > Since we are using no auth on the qpid broker anything we pass here
>> > will make us fail authentication.
>>
>> If you have disabled authentication in the broker then there should
>> not be any problem.
>> Could you please let us know if you are using the trunk broker or if
>> you are using a particular release.
>> Also please paste the output of the broker.
>>
>> > So we decided to try a form without a username/password. This seemed
>> > logical to us because we have python code that is not providing
>> > username/password.
>>
>> As explained above the code does not treat the userinfo as optional.
>>
>> > However, when we user a url without username:password info, The code
>> > throws an exception internally which is logged as a warning message to
>> > us:
>> > WARNING: Unable to createFactories:User information not found on url
>> > between indicies 7 and 1
>> >
>> > I dug through some of the java client code and found lines 86-111 of
>> > org/apache/qpid/client/url/URLParser.java is attempting to retrieve the
>> user
>> > info from the url string, and doesn't find it, so it stops parsing the
>> rest
>> > of the url and throws an exception. Control of the program then flows
>> back
>> > to the createFactory method of
>> > org/apache/qpid/jndi/PropertiesFileInitialContextFactory.java where the
>> > WARNING message is logged and ConnectionFactory is not created thus
>> cannot
>> > be used.
>> >
>> > Looking through the code I don't see any way for a java client to connect
>> > without providing credentials.
>> > Can anyone think of a work around?
>> >
>> > On Wed, Dec 9, 2009 at 6:18 PM, Rajith Attapattu <ra...@gmail.com>
>> wrote:
>> >
>> >> Could you please run the broker with -t and paste the output of the
>> broker?
>> >> Are you using a specific release of the c++ broker or is it built from
>> >> trunk?
>> >>
>> >> Rajith
>> >>
>> >> On Wed, Dec 9, 2009 at 6:08 PM, Glen Marchesani <gl...@model3.net>
>> wrote:
>> >> > Hi I am Brant's co-worker and can confirm the server is setup for
>> >> no-auth.
>> >> >
>> >> > We are trying to migrate working python code to work in the java
>> client
>> >> and
>> >> > as Brant has pointed out can't form a url for the java client that
>> works.
>> >> >
>> >> >
>> >> > On Wed, Dec 9, 2009 at 4:03 PM, Brant Boehmann <
>> brant.boehmann@gmail.com
>> >> >wrote:
>> >> >
>> >> >> I've tried with guest:guest and I get authentication failure shown in
>> >> the
>> >> >> stack trace. I think auth is already disabled on the server as the
>> >> python
>> >> >> code I posted works without providing credentials. If I remove guest:
>> >> guest
>> >> >> from the url then I get the error about the user info missing in the
>> url
>> >> >> and
>> >> >> I still can't connect. Does anyone have example java code of
>> connecting
>> >> to
>> >> >> a
>> >> >> c++ broker with auth disabled?
>> >> >>
>> >> >> On Dec 9, 2009 11:57 AM, "Rajith Attapattu" <ra...@gmail.com>
>> wrote:
>> >> >>
>> >> >> start the c++ broker with --auth no
>> >> >>
>> >> >> If you want authentication enabled, then need to setup SASL in the
>> c++
>> >> >> broker.
>> >> >> Sadly I couldn't find any documentation in the Qpid project, except
>> >> >> here https://issues.apache.org/jira/browse/QPID-648
>> >> >> If you set it up for the most basic case (username/password) then you
>> >> >> could use amqp://guest:guest@clientid
>> >> >> /test?brokerlist='tcp://localhost:5672'
>> >> >> where guest/guest is the user/pwd.
>> >> >>
>> >> >> Regards,
>> >> >>
>> >> >> Rajith
>> >> >>
>> >> >> On Tue, Dec 8, 2009 at 11:27 PM, Brant Boehmann <
>> >> brant.boehmann@gmail.com>
>> >> >> wrote: > I have a qpid C...
>> >> >> --
>> >> >> Regards,
>> >> >>
>> >> >> Rajith Attapattu
>> >> >> Red Hat
>> >> >> http://rajith.2rlabs.com/
>> >> >>
>> >> >> ---------------------------------------------------------------------
>> >> >> Apache Qpid - AMQP Messaging Implementation
>> >> >> Project:      http://qpid.apache.org
>> >> >> Use/Interact: mailto:users-subscribe@qpid.apache.org
>> >> >>
>> >> >
>> >>
>> >>
>> >>
>> >> --
>> >> Regards,
>> >>
>> >> Rajith Attapattu
>> >> Red Hat
>> >> http://rajith.2rlabs.com/
>> >>
>> >> ---------------------------------------------------------------------
>> >> Apache Qpid - AMQP Messaging Implementation
>> >> Project:      http://qpid.apache.org
>> >> Use/Interact: mailto:users-subscribe@qpid.apache.org
>> >>
>> >>
>> >
>>
>>
>>
>> --
>> Regards,
>>
>> Rajith Attapattu
>> Red Hat
>> http://rajith.2rlabs.com/
>>
>> ---------------------------------------------------------------------
>> Apache Qpid - AMQP Messaging Implementation
>> Project:      http://qpid.apache.org
>> Use/Interact: mailto:users-subscribe@qpid.apache.org
>>
>>
>



-- 
Regards,

Rajith Attapattu
Red Hat
http://rajith.2rlabs.com/

---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project:      http://qpid.apache.org
Use/Interact: mailto:users-subscribe@qpid.apache.org


RE: dotnet client 0.10 - performance

Posted by "Cliff Jansen (Interop Systems Inc)" <v-...@microsoft.com>.
Hi Ignacio,

If you are using durable messages, your test may be mainly measuring
the speed of the broker's message store on your hardware.

I have very little knowledge of the dotnet client, but using both the
qpid/wcf and qpid/cpp clients with a Linux broker give the following
numbers for 100 byte messages (using WcfPerftest and perftest
respectively):

  async:              66k msg/sec
  sync (not durable): 2.8k msg/sec
  sync (durable):     100 msg/sec

Which gives a similar amount of change between the first and third as
you are seeing.

My hardware consists of a couple of inexpensive desktops running
Windows (Client) and Fedora (broker) connected by a lowly 100Mbit/s
Ethernet switch.  The Linux broker's message store is in its default
configuration and "powered" by a single desktop 7200RPM drive.  I have
no doubt that with a little tuning and fancier storage hardware, the
durable number can be made to approach the non durable synchronous
number.

Cliff

-----Original Message-----
From: Ignacio Ybarra [mailto:ignacio_ybarra@hotmail.com] 
Sent: Thursday, December 10, 2009 9:20 AM
To: users@qpid.apache.org
Subject: dotnet client 0.10 - performance


Hi - has anybody benchmarked the dotnet client 0.10?
I am finding that a single publisher thread only goes as fast as 24 msg/sec (=41.6milliseconds/msg) when using this API in synchronous mode, i.e. 
            session.MessageTransfer("hello.exchange", myMessage);            session.Sync();
I am capturing the network traffic between the client and the broker and can see the message going to the broker (RHEL MRG) and coming back within ~2.1ms (implying a broker limitation of around 476msg/sec). The remaining time seems to be spent in code, somewhere between
	org.apache.qpid.transport.network.IoReceiver.Go()
	and
	org.apache.qpid.transport.Session.Complete(...) {... Monitor.PulseAll(_commands); ... }
which signals Session.Sync(...) { ... Monitor.Wait(_commands, (int)(timeout - elapsed)); ... } on the same class.
The payload is insignificant in this case - we are testing with small messages.
Async mode gives me 28K msgs/sec but the nature of this test requires a sync after each send.
Any help will be appreciated. 
TIA 
Ig


 		 	   		  

---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project:      http://qpid.apache.org
Use/Interact: mailto:users-subscribe@qpid.apache.org


dotnet client 0.10 - performance

Posted by Ignacio Ybarra <ig...@hotmail.com>.
Hi - has anybody benchmarked the dotnet client 0.10?
I am finding that a single publisher thread only goes as fast as 24 msg/sec (=41.6milliseconds/msg) when using this API in synchronous mode, i.e. 
            session.MessageTransfer("hello.exchange", myMessage);            session.Sync();
I am capturing the network traffic between the client and the broker and can see the message going to the broker (RHEL MRG) and coming back within ~2.1ms (implying a broker limitation of around 476msg/sec). The remaining time seems to be spent in code, somewhere between
	org.apache.qpid.transport.network.IoReceiver.Go()
	and
	org.apache.qpid.transport.Session.Complete(...) {... Monitor.PulseAll(_commands); ... }
which signals Session.Sync(...) { ... Monitor.Wait(_commands, (int)(timeout - elapsed)); ... } on the same class.
The payload is insignificant in this case - we are testing with small messages.
Async mode gives me 28K msgs/sec but the nature of this test requires a sync after each send.
Any help will be appreciated. 
TIA 
Ig


 		 	   		  

Re: dotnet client 0.10 - Sync() and Close()

Posted by Carl Trieloff <cc...@redhat.com>.
Coping Dev list.

Carl.


Ignacio Ybarra wrote:
> correction - TotalMilliseconds returns as a double so you will need to cast it:
> from:	(!) elapsed = DateTime.Now.Subtract(start).Milliseconds;to: elapsed = (int) DateTime.Now.Subtract(start).TotalMilliseconds;
> cheers
> ig
>
>   
>> From: ignacio_ybarra@hotmail.com
>> To: users@qpid.apache.org
>> Subject: dotnet client 0.10 - Sync() and Close()
>> Date: Thu, 10 Dec 2009 13:20:03 +0000
>>
>>
>> Hi - any chance someone could modify 
>>
>> http://svn.apache.org/viewvc/qpid/trunk/qpid/dotnet/client-010/client/transport/Session.cs
>>
>> lines 373 and 486 as per below:
>>
>> from:	(!) elapsed = DateTime.Now.Subtract(start).Milliseconds;
>>
>> to: 	elapsed = DateTime.Now.Subtract(start).TotalMilliseconds;
>>
>> The reason for this request is that TimeSpan.Milliseconds will always return a value between [-999,999].
>>
>> This means the condition (elapsed < timeout) in lines 368 and 483 will always be true with the default 
>>
>>         private const long _timeout = 600000;
>>
>> (or any timeout values >= 1000) which can lead to an infinite loop when calling Session.Sync() and Session.Close().
>>
>> Many thanks
>>
>> Ig
>>
>>  		 	   		  
>>     
>  		 	   		  
>   


Re: dotnet client 0.10 - Sync() and Close()

Posted by Carl Trieloff <cc...@redhat.com>.
Coping Dev list.

Carl.


Ignacio Ybarra wrote:
> correction - TotalMilliseconds returns as a double so you will need to cast it:
> from:	(!) elapsed = DateTime.Now.Subtract(start).Milliseconds;to: elapsed = (int) DateTime.Now.Subtract(start).TotalMilliseconds;
> cheers
> ig
>
>   
>> From: ignacio_ybarra@hotmail.com
>> To: users@qpid.apache.org
>> Subject: dotnet client 0.10 - Sync() and Close()
>> Date: Thu, 10 Dec 2009 13:20:03 +0000
>>
>>
>> Hi - any chance someone could modify 
>>
>> http://svn.apache.org/viewvc/qpid/trunk/qpid/dotnet/client-010/client/transport/Session.cs
>>
>> lines 373 and 486 as per below:
>>
>> from:	(!) elapsed = DateTime.Now.Subtract(start).Milliseconds;
>>
>> to: 	elapsed = DateTime.Now.Subtract(start).TotalMilliseconds;
>>
>> The reason for this request is that TimeSpan.Milliseconds will always return a value between [-999,999].
>>
>> This means the condition (elapsed < timeout) in lines 368 and 483 will always be true with the default 
>>
>>         private const long _timeout = 600000;
>>
>> (or any timeout values >= 1000) which can lead to an infinite loop when calling Session.Sync() and Session.Close().
>>
>> Many thanks
>>
>> Ig
>>
>>  		 	   		  
>>     
>  		 	   		  
>   


RE: dotnet client 0.10 - Sync() and Close()

Posted by Ignacio Ybarra <ig...@hotmail.com>.
correction - TotalMilliseconds returns as a double so you will need to cast it:
from:	(!) elapsed = DateTime.Now.Subtract(start).Milliseconds;to: elapsed = (int) DateTime.Now.Subtract(start).TotalMilliseconds;
cheers
ig

> From: ignacio_ybarra@hotmail.com
> To: users@qpid.apache.org
> Subject: dotnet client 0.10 - Sync() and Close()
> Date: Thu, 10 Dec 2009 13:20:03 +0000
> 
> 
> Hi - any chance someone could modify 
> 
> http://svn.apache.org/viewvc/qpid/trunk/qpid/dotnet/client-010/client/transport/Session.cs
> 
> lines 373 and 486 as per below:
> 
> from:	(!) elapsed = DateTime.Now.Subtract(start).Milliseconds;
> 
> to: 	elapsed = DateTime.Now.Subtract(start).TotalMilliseconds;
> 
> The reason for this request is that TimeSpan.Milliseconds will always return a value between [-999,999].
> 
> This means the condition (elapsed < timeout) in lines 368 and 483 will always be true with the default 
> 
>         private const long _timeout = 600000;
> 
> (or any timeout values >= 1000) which can lead to an infinite loop when calling Session.Sync() and Session.Close().
> 
> Many thanks
> 
> Ig
> 
>  		 	   		  
 		 	   		  

dotnet client 0.10 - Sync() and Close()

Posted by Ignacio Ybarra <ig...@hotmail.com>.
Hi - any chance someone could modify 

http://svn.apache.org/viewvc/qpid/trunk/qpid/dotnet/client-010/client/transport/Session.cs

lines 373 and 486 as per below:

from:	(!) elapsed = DateTime.Now.Subtract(start).Milliseconds;

to: 	elapsed = DateTime.Now.Subtract(start).TotalMilliseconds;

The reason for this request is that TimeSpan.Milliseconds will always return a value between [-999,999].

This means the condition (elapsed < timeout) in lines 368 and 483 will always be true with the default 

        private const long _timeout = 600000;

(or any timeout values > 1000) which can lead to an infinite loop when calling Session.Sync() and Session.Close().

Many thanks

Ig

 		 	   		  

Re: C++ broker, java client

Posted by Glen Marchesani <gl...@model3.net>.
Hi Rajith,
Thanks for your help and quick responses.  It looks like our issue was
related to a bad build of qpid.  My apologies for this.  In short when I ran
it with the "qpidd -t" option.  I had to do it on a different machine and
when I ran our example java code it worked (with the url of
amqp://guest:guest@clientid/test?brokerlist='tcp://172.16.1.52:5672').  The
issue was the qpidd server we were originally using as I went back to that
and saw the issue again.

We were running qpid C++ 0.5 daemon.

One interesting note is the performance of our python client was around 1000
msgs/second.  With the java client we are seeing something closer to 10,000
msgs/second.  Very informal tests but enough that I thought it worth
mentioning.



On Wed, Dec 9, 2009 at 9:59 PM, Rajith Attapattu <ra...@gmail.com> wrote:

> On Wed, Dec 9, 2009 at 8:57 PM, Brant Boehmann <br...@gmail.com>
> wrote:
> > I think Glen will be running your test soon, but I may have stumbled
> across
> > the issue while digging through qpid code.
> >
> > The docs say a url of the form: It
> >
> >
> amqp://[<user>:<pass>@][<clientid>]<virtualhost>[?<option>='<value>'[&<option>='<value>']]
> >
> > It then goes on to give examples like:
> >
> > amqp:///test?brokerlist='localhost'
> > amqp:///test?brokerlist='tcp://anotherhost:5684?retries='10''
> > amqp://guest:guest@
> /test?brokerlist='vm://:1;vm://:2'&failover='roundrobin'
> > amqp://guest:guest@
> /test?brokerlist='vm://:1;vm://:2'&failover='roundrobin?cyclecount='20''
> > amqp://guest:guest@client
> /test?brokerlist='tcp://localhost;tcp://redundant-server:5673?ssl='true''&failover='roundrobin'
> > amqp://guest:guest@/test?brokerlist='vm://:1'&failover='nofailover'
> >
> >
> >
> > This implies that the user info (ie guest:guest) are not required.
>
> Yes the documentation does imply that, all though the code doesn't reflect
> it.
> I sincerely apologize for this mistake.
> One of the biggest issues we have right now is that our documentation
> is sometimes out of sync with the code.
> We are trying to address this as a matter of priority.
>
> All though the code treats the user_info as mandatory sometimes it
> doesn't make sense especially when using mechanisms like anon or
> kerberos.
> So IMO the documentation is correct and the username/password should
> be optional.
> However looking at the svn history, it seems that the user info has
> always been treated mandatory.
>
> We should either fix the code or the documentation.
> Would you like to create a JIRA for this?
> Again sorry for the inconvenience.
>
> > Since we are using no auth on the qpid broker anything we pass here
> > will make us fail authentication.
>
> If you have disabled authentication in the broker then there should
> not be any problem.
> Could you please let us know if you are using the trunk broker or if
> you are using a particular release.
> Also please paste the output of the broker.
>
> > So we decided to try a form without a username/password. This seemed
> > logical to us because we have python code that is not providing
> > username/password.
>
> As explained above the code does not treat the userinfo as optional.
>
> > However, when we user a url without username:password info, The code
> > throws an exception internally which is logged as a warning message to
> > us:
> > WARNING: Unable to createFactories:User information not found on url
> > between indicies 7 and 1
> >
> > I dug through some of the java client code and found lines 86-111 of
> > org/apache/qpid/client/url/URLParser.java is attempting to retrieve the
> user
> > info from the url string, and doesn't find it, so it stops parsing the
> rest
> > of the url and throws an exception. Control of the program then flows
> back
> > to the createFactory method of
> > org/apache/qpid/jndi/PropertiesFileInitialContextFactory.java where the
> > WARNING message is logged and ConnectionFactory is not created thus
> cannot
> > be used.
> >
> > Looking through the code I don't see any way for a java client to connect
> > without providing credentials.
> > Can anyone think of a work around?
> >
> > On Wed, Dec 9, 2009 at 6:18 PM, Rajith Attapattu <ra...@gmail.com>
> wrote:
> >
> >> Could you please run the broker with -t and paste the output of the
> broker?
> >> Are you using a specific release of the c++ broker or is it built from
> >> trunk?
> >>
> >> Rajith
> >>
> >> On Wed, Dec 9, 2009 at 6:08 PM, Glen Marchesani <gl...@model3.net>
> wrote:
> >> > Hi I am Brant's co-worker and can confirm the server is setup for
> >> no-auth.
> >> >
> >> > We are trying to migrate working python code to work in the java
> client
> >> and
> >> > as Brant has pointed out can't form a url for the java client that
> works.
> >> >
> >> >
> >> > On Wed, Dec 9, 2009 at 4:03 PM, Brant Boehmann <
> brant.boehmann@gmail.com
> >> >wrote:
> >> >
> >> >> I've tried with guest:guest and I get authentication failure shown in
> >> the
> >> >> stack trace. I think auth is already disabled on the server as the
> >> python
> >> >> code I posted works without providing credentials. If I remove guest:
> >> guest
> >> >> from the url then I get the error about the user info missing in the
> url
> >> >> and
> >> >> I still can't connect. Does anyone have example java code of
> connecting
> >> to
> >> >> a
> >> >> c++ broker with auth disabled?
> >> >>
> >> >> On Dec 9, 2009 11:57 AM, "Rajith Attapattu" <ra...@gmail.com>
> wrote:
> >> >>
> >> >> start the c++ broker with --auth no
> >> >>
> >> >> If you want authentication enabled, then need to setup SASL in the
> c++
> >> >> broker.
> >> >> Sadly I couldn't find any documentation in the Qpid project, except
> >> >> here https://issues.apache.org/jira/browse/QPID-648
> >> >> If you set it up for the most basic case (username/password) then you
> >> >> could use amqp://guest:guest@clientid
> >> >> /test?brokerlist='tcp://localhost:5672'
> >> >> where guest/guest is the user/pwd.
> >> >>
> >> >> Regards,
> >> >>
> >> >> Rajith
> >> >>
> >> >> On Tue, Dec 8, 2009 at 11:27 PM, Brant Boehmann <
> >> brant.boehmann@gmail.com>
> >> >> wrote: > I have a qpid C...
> >> >> --
> >> >> Regards,
> >> >>
> >> >> Rajith Attapattu
> >> >> Red Hat
> >> >> http://rajith.2rlabs.com/
> >> >>
> >> >> ---------------------------------------------------------------------
> >> >> Apache Qpid - AMQP Messaging Implementation
> >> >> Project:      http://qpid.apache.org
> >> >> Use/Interact: mailto:users-subscribe@qpid.apache.org
> >> >>
> >> >
> >>
> >>
> >>
> >> --
> >> Regards,
> >>
> >> Rajith Attapattu
> >> Red Hat
> >> http://rajith.2rlabs.com/
> >>
> >> ---------------------------------------------------------------------
> >> Apache Qpid - AMQP Messaging Implementation
> >> Project:      http://qpid.apache.org
> >> Use/Interact: mailto:users-subscribe@qpid.apache.org
> >>
> >>
> >
>
>
>
> --
> Regards,
>
> Rajith Attapattu
> Red Hat
> http://rajith.2rlabs.com/
>
> ---------------------------------------------------------------------
> Apache Qpid - AMQP Messaging Implementation
> Project:      http://qpid.apache.org
> Use/Interact: mailto:users-subscribe@qpid.apache.org
>
>

Re: C++ broker, java client

Posted by Rajith Attapattu <ra...@gmail.com>.
On Wed, Dec 9, 2009 at 8:57 PM, Brant Boehmann <br...@gmail.com> wrote:
> I think Glen will be running your test soon, but I may have stumbled across
> the issue while digging through qpid code.
>
> The docs say a url of the form: It
>
> amqp://[<user>:<pass>@][<clientid>]<virtualhost>[?<option>='<value>'[&<option>='<value>']]
>
> It then goes on to give examples like:
>
> amqp:///test?brokerlist='localhost'
> amqp:///test?brokerlist='tcp://anotherhost:5684?retries='10''
> amqp://guest:guest@/test?brokerlist='vm://:1;vm://:2'&failover='roundrobin'
> amqp://guest:guest@/test?brokerlist='vm://:1;vm://:2'&failover='roundrobin?cyclecount='20''
> amqp://guest:guest@client/test?brokerlist='tcp://localhost;tcp://redundant-server:5673?ssl='true''&failover='roundrobin'
> amqp://guest:guest@/test?brokerlist='vm://:1'&failover='nofailover'
>
>
>
> This implies that the user info (ie guest:guest) are not required.

Yes the documentation does imply that, all though the code doesn't reflect it.
I sincerely apologize for this mistake.
One of the biggest issues we have right now is that our documentation
is sometimes out of sync with the code.
We are trying to address this as a matter of priority.

All though the code treats the user_info as mandatory sometimes it
doesn't make sense especially when using mechanisms like anon or
kerberos.
So IMO the documentation is correct and the username/password should
be optional.
However looking at the svn history, it seems that the user info has
always been treated mandatory.

We should either fix the code or the documentation.
Would you like to create a JIRA for this?
Again sorry for the inconvenience.

> Since we are using no auth on the qpid broker anything we pass here
> will make us fail authentication.

If you have disabled authentication in the broker then there should
not be any problem.
Could you please let us know if you are using the trunk broker or if
you are using a particular release.
Also please paste the output of the broker.

> So we decided to try a form without a username/password. This seemed
> logical to us because we have python code that is not providing
> username/password.

As explained above the code does not treat the userinfo as optional.

> However, when we user a url without username:password info, The code
> throws an exception internally which is logged as a warning message to
> us:
> WARNING: Unable to createFactories:User information not found on url
> between indicies 7 and 1
>
> I dug through some of the java client code and found lines 86-111 of
> org/apache/qpid/client/url/URLParser.java is attempting to retrieve the user
> info from the url string, and doesn't find it, so it stops parsing the rest
> of the url and throws an exception. Control of the program then flows back
> to the createFactory method of
> org/apache/qpid/jndi/PropertiesFileInitialContextFactory.java where the
> WARNING message is logged and ConnectionFactory is not created thus cannot
> be used.
>
> Looking through the code I don't see any way for a java client to connect
> without providing credentials.
> Can anyone think of a work around?
>
> On Wed, Dec 9, 2009 at 6:18 PM, Rajith Attapattu <ra...@gmail.com> wrote:
>
>> Could you please run the broker with -t and paste the output of the broker?
>> Are you using a specific release of the c++ broker or is it built from
>> trunk?
>>
>> Rajith
>>
>> On Wed, Dec 9, 2009 at 6:08 PM, Glen Marchesani <gl...@model3.net> wrote:
>> > Hi I am Brant's co-worker and can confirm the server is setup for
>> no-auth.
>> >
>> > We are trying to migrate working python code to work in the java client
>> and
>> > as Brant has pointed out can't form a url for the java client that works.
>> >
>> >
>> > On Wed, Dec 9, 2009 at 4:03 PM, Brant Boehmann <brant.boehmann@gmail.com
>> >wrote:
>> >
>> >> I've tried with guest:guest and I get authentication failure shown in
>> the
>> >> stack trace. I think auth is already disabled on the server as the
>> python
>> >> code I posted works without providing credentials. If I remove guest:
>> guest
>> >> from the url then I get the error about the user info missing in the url
>> >> and
>> >> I still can't connect. Does anyone have example java code of connecting
>> to
>> >> a
>> >> c++ broker with auth disabled?
>> >>
>> >> On Dec 9, 2009 11:57 AM, "Rajith Attapattu" <ra...@gmail.com> wrote:
>> >>
>> >> start the c++ broker with --auth no
>> >>
>> >> If you want authentication enabled, then need to setup SASL in the c++
>> >> broker.
>> >> Sadly I couldn't find any documentation in the Qpid project, except
>> >> here https://issues.apache.org/jira/browse/QPID-648
>> >> If you set it up for the most basic case (username/password) then you
>> >> could use amqp://guest:guest@clientid
>> >> /test?brokerlist='tcp://localhost:5672'
>> >> where guest/guest is the user/pwd.
>> >>
>> >> Regards,
>> >>
>> >> Rajith
>> >>
>> >> On Tue, Dec 8, 2009 at 11:27 PM, Brant Boehmann <
>> brant.boehmann@gmail.com>
>> >> wrote: > I have a qpid C...
>> >> --
>> >> Regards,
>> >>
>> >> Rajith Attapattu
>> >> Red Hat
>> >> http://rajith.2rlabs.com/
>> >>
>> >> ---------------------------------------------------------------------
>> >> Apache Qpid - AMQP Messaging Implementation
>> >> Project:      http://qpid.apache.org
>> >> Use/Interact: mailto:users-subscribe@qpid.apache.org
>> >>
>> >
>>
>>
>>
>> --
>> Regards,
>>
>> Rajith Attapattu
>> Red Hat
>> http://rajith.2rlabs.com/
>>
>> ---------------------------------------------------------------------
>> Apache Qpid - AMQP Messaging Implementation
>> Project:      http://qpid.apache.org
>> Use/Interact: mailto:users-subscribe@qpid.apache.org
>>
>>
>



-- 
Regards,

Rajith Attapattu
Red Hat
http://rajith.2rlabs.com/

---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project:      http://qpid.apache.org
Use/Interact: mailto:users-subscribe@qpid.apache.org


Re: C++ broker, java client

Posted by Brant Boehmann <br...@gmail.com>.
I think Glen will be running your test soon, but I may have stumbled across
the issue while digging through qpid code.

The docs say a url of the form: It

amqp://[<user>:<pass>@][<clientid>]<virtualhost>[?<option>='<value>'[&<option>='<value>']]

It then goes on to give examples like:

amqp:///test?brokerlist='localhost'
amqp:///test?brokerlist='tcp://anotherhost:5684?retries='10''
amqp://guest:guest@/test?brokerlist='vm://:1;vm://:2'&failover='roundrobin'
amqp://guest:guest@/test?brokerlist='vm://:1;vm://:2'&failover='roundrobin?cyclecount='20''
amqp://guest:guest@client/test?brokerlist='tcp://localhost;tcp://redundant-server:5673?ssl='true''&failover='roundrobin'
amqp://guest:guest@/test?brokerlist='vm://:1'&failover='nofailover'



This implies that the user info (ie guest:guest) are not required.
Since we are using no auth on the qpid broker anything we pass here
will make us fail authentication.
So we decided to try a form without a username/password. This seemed
logical to us because we have python code that is not providing
username/password.
However, when we user a url without username:password info, The code
throws an exception internally which is logged as a warning message to
us:
WARNING: Unable to createFactories:User information not found on url
between indicies 7 and 1

I dug through some of the java client code and found lines 86-111 of
org/apache/qpid/client/url/URLParser.java is attempting to retrieve the user
info from the url string, and doesn't find it, so it stops parsing the rest
of the url and throws an exception. Control of the program then flows back
to the createFactory method of
org/apache/qpid/jndi/PropertiesFileInitialContextFactory.java where the
WARNING message is logged and ConnectionFactory is not created thus cannot
be used.

Looking through the code I don't see any way for a java client to connect
without providing credentials.
Can anyone think of a work around?

On Wed, Dec 9, 2009 at 6:18 PM, Rajith Attapattu <ra...@gmail.com> wrote:

> Could you please run the broker with -t and paste the output of the broker?
> Are you using a specific release of the c++ broker or is it built from
> trunk?
>
> Rajith
>
> On Wed, Dec 9, 2009 at 6:08 PM, Glen Marchesani <gl...@model3.net> wrote:
> > Hi I am Brant's co-worker and can confirm the server is setup for
> no-auth.
> >
> > We are trying to migrate working python code to work in the java client
> and
> > as Brant has pointed out can't form a url for the java client that works.
> >
> >
> > On Wed, Dec 9, 2009 at 4:03 PM, Brant Boehmann <brant.boehmann@gmail.com
> >wrote:
> >
> >> I've tried with guest:guest and I get authentication failure shown in
> the
> >> stack trace. I think auth is already disabled on the server as the
> python
> >> code I posted works without providing credentials. If I remove guest:
> guest
> >> from the url then I get the error about the user info missing in the url
> >> and
> >> I still can't connect. Does anyone have example java code of connecting
> to
> >> a
> >> c++ broker with auth disabled?
> >>
> >> On Dec 9, 2009 11:57 AM, "Rajith Attapattu" <ra...@gmail.com> wrote:
> >>
> >> start the c++ broker with --auth no
> >>
> >> If you want authentication enabled, then need to setup SASL in the c++
> >> broker.
> >> Sadly I couldn't find any documentation in the Qpid project, except
> >> here https://issues.apache.org/jira/browse/QPID-648
> >> If you set it up for the most basic case (username/password) then you
> >> could use amqp://guest:guest@clientid
> >> /test?brokerlist='tcp://localhost:5672'
> >> where guest/guest is the user/pwd.
> >>
> >> Regards,
> >>
> >> Rajith
> >>
> >> On Tue, Dec 8, 2009 at 11:27 PM, Brant Boehmann <
> brant.boehmann@gmail.com>
> >> wrote: > I have a qpid C...
> >> --
> >> Regards,
> >>
> >> Rajith Attapattu
> >> Red Hat
> >> http://rajith.2rlabs.com/
> >>
> >> ---------------------------------------------------------------------
> >> Apache Qpid - AMQP Messaging Implementation
> >> Project:      http://qpid.apache.org
> >> Use/Interact: mailto:users-subscribe@qpid.apache.org
> >>
> >
>
>
>
> --
> Regards,
>
> Rajith Attapattu
> Red Hat
> http://rajith.2rlabs.com/
>
> ---------------------------------------------------------------------
> Apache Qpid - AMQP Messaging Implementation
> Project:      http://qpid.apache.org
> Use/Interact: mailto:users-subscribe@qpid.apache.org
>
>

Re: C++ broker, java client

Posted by Rajith Attapattu <ra...@gmail.com>.
Could you please run the broker with -t and paste the output of the broker?
Are you using a specific release of the c++ broker or is it built from trunk?

Rajith

On Wed, Dec 9, 2009 at 6:08 PM, Glen Marchesani <gl...@model3.net> wrote:
> Hi I am Brant's co-worker and can confirm the server is setup for no-auth.
>
> We are trying to migrate working python code to work in the java client and
> as Brant has pointed out can't form a url for the java client that works.
>
>
> On Wed, Dec 9, 2009 at 4:03 PM, Brant Boehmann <br...@gmail.com>wrote:
>
>> I've tried with guest:guest and I get authentication failure shown in the
>> stack trace. I think auth is already disabled on the server as the python
>> code I posted works without providing credentials. If I remove guest: guest
>> from the url then I get the error about the user info missing in the url
>> and
>> I still can't connect. Does anyone have example java code of connecting to
>> a
>> c++ broker with auth disabled?
>>
>> On Dec 9, 2009 11:57 AM, "Rajith Attapattu" <ra...@gmail.com> wrote:
>>
>> start the c++ broker with --auth no
>>
>> If you want authentication enabled, then need to setup SASL in the c++
>> broker.
>> Sadly I couldn't find any documentation in the Qpid project, except
>> here https://issues.apache.org/jira/browse/QPID-648
>> If you set it up for the most basic case (username/password) then you
>> could use amqp://guest:guest@clientid
>> /test?brokerlist='tcp://localhost:5672'
>> where guest/guest is the user/pwd.
>>
>> Regards,
>>
>> Rajith
>>
>> On Tue, Dec 8, 2009 at 11:27 PM, Brant Boehmann <br...@gmail.com>
>> wrote: > I have a qpid C...
>> --
>> Regards,
>>
>> Rajith Attapattu
>> Red Hat
>> http://rajith.2rlabs.com/
>>
>> ---------------------------------------------------------------------
>> Apache Qpid - AMQP Messaging Implementation
>> Project:      http://qpid.apache.org
>> Use/Interact: mailto:users-subscribe@qpid.apache.org
>>
>



-- 
Regards,

Rajith Attapattu
Red Hat
http://rajith.2rlabs.com/

---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project:      http://qpid.apache.org
Use/Interact: mailto:users-subscribe@qpid.apache.org


Re: C++ broker, java client

Posted by Glen Marchesani <gl...@model3.net>.
Hi I am Brant's co-worker and can confirm the server is setup for no-auth.

We are trying to migrate working python code to work in the java client and
as Brant has pointed out can't form a url for the java client that works.


On Wed, Dec 9, 2009 at 4:03 PM, Brant Boehmann <br...@gmail.com>wrote:

> I've tried with guest:guest and I get authentication failure shown in the
> stack trace. I think auth is already disabled on the server as the python
> code I posted works without providing credentials. If I remove guest: guest
> from the url then I get the error about the user info missing in the url
> and
> I still can't connect. Does anyone have example java code of connecting to
> a
> c++ broker with auth disabled?
>
> On Dec 9, 2009 11:57 AM, "Rajith Attapattu" <ra...@gmail.com> wrote:
>
> start the c++ broker with --auth no
>
> If you want authentication enabled, then need to setup SASL in the c++
> broker.
> Sadly I couldn't find any documentation in the Qpid project, except
> here https://issues.apache.org/jira/browse/QPID-648
> If you set it up for the most basic case (username/password) then you
> could use amqp://guest:guest@clientid
> /test?brokerlist='tcp://localhost:5672'
> where guest/guest is the user/pwd.
>
> Regards,
>
> Rajith
>
> On Tue, Dec 8, 2009 at 11:27 PM, Brant Boehmann <br...@gmail.com>
> wrote: > I have a qpid C...
> --
> Regards,
>
> Rajith Attapattu
> Red Hat
> http://rajith.2rlabs.com/
>
> ---------------------------------------------------------------------
> Apache Qpid - AMQP Messaging Implementation
> Project:      http://qpid.apache.org
> Use/Interact: mailto:users-subscribe@qpid.apache.org
>

Re: C++ broker, java client

Posted by Brant Boehmann <br...@gmail.com>.
I've tried with guest:guest and I get authentication failure shown in the
stack trace. I think auth is already disabled on the server as the python
code I posted works without providing credentials. If I remove guest: guest
from the url then I get the error about the user info missing in the url and
I still can't connect. Does anyone have example java code of connecting to a
c++ broker with auth disabled?

On Dec 9, 2009 11:57 AM, "Rajith Attapattu" <ra...@gmail.com> wrote:

start the c++ broker with --auth no

If you want authentication enabled, then need to setup SASL in the c++
broker.
Sadly I couldn't find any documentation in the Qpid project, except
here https://issues.apache.org/jira/browse/QPID-648
If you set it up for the most basic case (username/password) then you
could use amqp://guest:guest@clientid/test?brokerlist='tcp://localhost:5672'
where guest/guest is the user/pwd.

Regards,

Rajith

On Tue, Dec 8, 2009 at 11:27 PM, Brant Boehmann <br...@gmail.com>
wrote: > I have a qpid C...
--
Regards,

Rajith Attapattu
Red Hat
http://rajith.2rlabs.com/

---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project:      http://qpid.apache.org
Use/Interact: mailto:users-subscribe@qpid.apache.org

Re: C++ broker, java client

Posted by Rajith Attapattu <ra...@gmail.com>.
start the c++ broker with --auth no

If you want authentication enabled, then need to setup SASL in the c++ broker.
Sadly I couldn't find any documentation in the Qpid project, except
here https://issues.apache.org/jira/browse/QPID-648
If you set it up for the most basic case (username/password) then you
could use amqp://guest:guest@clientid/test?brokerlist='tcp://localhost:5672'
where guest/guest is the user/pwd.

Regards,

Rajith

On Tue, Dec 8, 2009 at 11:27 PM, Brant Boehmann
<br...@gmail.com> wrote:
> I have a qpid C++ broker, and I'm trying to learn how to utilize the java
> client to publish and receive messages via JMS.
> When I try to connect with the url from the
> example(connectionfactory.qpidConnectionfactory =
> amqp://guest:guest@clientid/test?brokerlist='tcp://localhost:5672')
>
> I get the stack trace at the bottom of the message indication authentication
> failure. I'm told the qpid broker I'm connecting to has no ACL enabled, and
> there is python code working which does not utilize a username and password
> when creating a connection:
>
> ...
> sock = connect(self.host, self.port)
> ...
> self.conn      = Connection(sock=sock)
> ...
>
> If I attempt to use a simpler url of the form
> amqp:///test?brokerlist='localhost'
>
> I get the following message:
>
> WARNING: Unable to createFactories:User information not found on url between
> indicies 7 and 1
> amqp:///test?brokerlist='localhost'
>       ^
> javax.naming.NameNotFoundException: qpidConnectionfactory
>
>
>
>
> How do I enter no username/password in the Connection URL for java?
> What specifically is the clientid & virtualhost in the Connection URL as I
> don't see an equivalent in the python examples?
> Please help me get connected. I'm currently just using the JMS pubsub
> samples from svn.
>
>
> -------------STACK TRACE___________________________________
> Dec 8, 2009 10:50:54 PM
> org.apache.qpid.jndi.PropertiesFileInitialContextFactory getInitialContext
> INFO: No Provider URL specified.
> Dec 8, 2009 10:50:54 PM org.apache.qpid.jms.failover.FailoverSingleServer
> getNextBrokerDetails
> INFO: No delay between connect retries, use
> tcp://host:port?connectdelay='value' to enable.
> Dec 8, 2009 10:50:54 PM org.apache.qpid.client.AMQConnection <init>
> INFO:
> Connection:amqp://guest:********@bb/test?brokerlist='tcp://localhost:5672'
> Dec 8, 2009 10:50:54 PM org.apache.qpid.client.AMQConnection <init>
> INFO: Unable to connect to broker at tcp://localhost:5672
> org.apache.qpid.AMQException: cannot connect to broker [error code 504:
> channel error]
>        at
> org.apache.qpid.client.AMQConnectionDelegate_0_10.makeBrokerConnection(AMQConnectionDelegate_0_10.java:172)
>        at
> org.apache.qpid.client.AMQConnection.makeBrokerConnection(AMQConnection.java:728)
>        at
> org.apache.qpid.client.AMQConnection.<init>(AMQConnection.java:520)
>        at
> org.apache.qpid.client.AMQConnectionFactory.createConnection(AMQConnectionFactory.java:276)
>        at Listener.runTest(Listener.java:75)
>        at Listener.main(Listener.java:45)
> Caused by: org.apache.qpid.transport.ConnectionException: connection-forced:
> Authentication failed
>        at
> org.apache.qpid.transport.ConnectionException.rethrow(ConnectionException.java:67)
>        at org.apache.qpid.transport.Connection.connect(Connection.java:202)
>        at
> org.apache.qpid.client.AMQConnectionDelegate_0_10.makeBrokerConnection(AMQConnectionDelegate_0_10.java:161)
>        ... 5 more
> Caused by: org.apache.qpid.transport.ConnectionException: connection-forced:
> Authentication failed
>        at
> org.apache.qpid.transport.Connection.closeCode(Connection.java:419)
>        at
> org.apache.qpid.transport.ConnectionDelegate.connectionClose(ConnectionDelegate.java:76)
>        at
> org.apache.qpid.transport.ConnectionDelegate.connectionClose(ConnectionDelegate.java:40)
>        at
> org.apache.qpid.transport.ConnectionClose.dispatch(ConnectionClose.java:91)
>        at
> org.apache.qpid.transport.ConnectionDelegate.control(ConnectionDelegate.java:49)
>        at
> org.apache.qpid.transport.ConnectionDelegate.control(ConnectionDelegate.java:40)
>        at org.apache.qpid.transport.Method.delegate(Method.java:151)
>        at
> org.apache.qpid.transport.Connection.received(Connection.java:285)
>        at org.apache.qpid.transport.Connection.received(Connection.java:52)
>        at
> org.apache.qpid.transport.network.Assembler.emit(Assembler.java:98)
>        at
> org.apache.qpid.transport.network.Assembler.assemble(Assembler.java:184)
>        at
> org.apache.qpid.transport.network.Assembler.frame(Assembler.java:132)
>        at org.apache.qpid.transport.network.Frame.delegate(Frame.java:133)
>        at
> org.apache.qpid.transport.network.Assembler.received(Assembler.java:103)
>        at
> org.apache.qpid.transport.network.Assembler.received(Assembler.java:48)
>        at
> org.apache.qpid.transport.network.InputHandler.next(InputHandler.java:186)
>        at
> org.apache.qpid.transport.network.InputHandler.received(InputHandler.java:103)
>        at
> org.apache.qpid.transport.network.InputHandler.received(InputHandler.java:42)
>        at
> org.apache.qpid.transport.network.io.IoReceiver.run(IoReceiver.java:128)
>        at java.lang.Thread.run(Thread.java:619)
> Dec 8, 2009 10:50:54 PM org.apache.qpid.jms.failover.FailoverSingleServer
> getNextBrokerDetails
> INFO: No delay between connect retries, use
> tcp://host:port?connectdelay='value' to enable.
>



-- 
Regards,

Rajith Attapattu
Red Hat
http://rajith.2rlabs.com/

---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project:      http://qpid.apache.org
Use/Interact: mailto:users-subscribe@qpid.apache.org