I'm attempting to connect my Coldfusion app to CloudAMQP's RabbitMQ service. I've been able to create the java object, but when I attempt to create a newConnection(), it fails miserably. I'm thinking it may have something to do with my config? Here's how I've mapped AMQP's settings (right) to my code (left). I'm basically following Luis Majano's example code on github (lmajano/messaging-polyglot) which he refers to in his video Down the RabbitMQ Hole with ColdFusion
NOTE: I will rotate the password after posting, so these credentials won't work. Seems like the prudent thing to do :)
When I run this code I'm able to create a factory successfully. The writeDump(factory)
code outputs the following.
NOTE: the newConnection() method
Now, when I attempt to actually create a connection factory.newConnection()
like so...
it fails! Here is the result of the dump within the catch writeDump(err)
Any idea why it would be failing on the factory.newConnection()
method call?
Set the vhost:
factory.setVirtualHost("vhost");
The vhost is the same as the username for shared cloudamqp instances.