qpid-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Brant Boehmann <brant.boehm...@gmail.com>
Subject C++ broker, java client
Date Wed, 09 Dec 2009 04:27:10 GMT
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.

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message