[Rhm-users] Getting started with C++ broker

Andy Grove andy at codesuccess.com
Fri Oct 19 07:34:58 UTC 2007


Hi,

I have just started using RHM. I have a Java client which works correctly
when I run it against the Java broker. I am now trying to use the C++ broker
for performance reasons. I installed the broker using "yum install qpidd" on
a 64 bit Intel machine running an early version of Fedora 8. The install ran
smoothly and the broker appears to be running ok,

When I run my client it basically seems to time out with this error:

javax.jms.JMSException: Error creating connection: State not achieved within
permitted time.  Current state AMQState: id = 1 name:
CONNECTION_NOT_STARTED, desired state: AMQState: id = 4 name:
CONNECTION_OPEN

After I get this error I see some output on the broker:

Closing socket 0x60b230 at 0x625f70
Session closed [0x625f70]

This is the code I am using to get a connection.

            InitialContext ctx = new InitialContext(properties);
            AMQConnectionFactory cf = (AMQConnectionFactory) ctx.lookup
("local");
            Connection connection = cf.createConnection();

These are the properties I am passing in to the InitialContext:

java.naming.factory.initial =
org.apache.qpid.jndi.PropertiesFileInitialContextFactory
connectionfactory.local = amqp://guest:guest@clientid
/test?brokerlist='tcp://192.168.1.14:5672'

To summarize, this works fine when I run against a Java broker on the same
machine but fails if I run it against a remote C++ broker. I've disabled the
firewall on the broker machine so that's not the issue.

I would appreciate some pointers so I can debug this further.

Thanks,

Andy.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listman.redhat.com/archives/rhm-users/attachments/20071019/64fc67fa/attachment.htm>


More information about the Rhm-users mailing list