I was trying to implement Windows Service Bus 1.1 with AMQP for my project, I have installed Windows Service Bus 1.1 and created a Queue with the name test using Service Bus Explorer, I am testing the sample Service bus functionality with the Java program given in the below link,
https://msdn.microsoft.com/en-us/library/dn574799.aspx
In the example given above link i have removed if else code starting with if(type.compareTo("onprem") == 0) and hard coded my connection string.
And creating the producer as below
Destination que = (Destination) context.lookup("QUEUE"); // reading form properties file
producer = session.createProducer(que);
My connection string and Queue name looks like the below one
connectionstring = amqps://username:pwd@machinename/SampleNameSpace
QueueName = SampleNameSpace/test
When i run the Java program i am getting the ConcurrentTimeOutException when creating the producer.
I am pretty much new to the Service Bus thing and i tried to find out some solution online but it wasn't successful.
Below is my console log
Initial setup
Creating context
Creating connection factory
Creating connection
Creating session
Creating queue
Creating producer
Exception creating producer
javax.jms.JMSException: java.util.concurrent.TimeoutException
at org.apache.qpid.amqp_1_0.jms.impl.MessageProducerImpl.<init>(MessageProducerImpl.java:98)
at org.apache.qpid.amqp_1_0.jms.impl.SessionImpl.createProducer(SessionImpl.java:390)
at org.apache.qpid.amqp_1_0.jms.impl.SessionImpl.createProducer(SessionImpl.java:59)
at prerna.jms.test.SBTest.main(SBTest.java:71)
Caused by: org.apache.qpid.amqp_1_0.client.Sender$SenderCreationException: java.util.concurrent.TimeoutException
at org.apache.qpid.amqp_1_0.client.Sender.<init>(Sender.java:178)
at org.apache.qpid.amqp_1_0.client.Sender.<init>(Sender.java:119)
at org.apache.qpid.amqp_1_0.client.Sender.<init>(Sender.java:112)
at org.apache.qpid.amqp_1_0.client.Sender.<init>(Sender.java:98)
at org.apache.qpid.amqp_1_0.client.Sender.<init>(Sender.java:84)
at org.apache.qpid.amqp_1_0.client.Sender.<init>(Sender.java:78)
at org.apache.qpid.amqp_1_0.client.Session$1.<init>(Session.java:90)
at org.apache.qpid.amqp_1_0.client.Session.createSender(Session.java:89)
at org.apache.qpid.amqp_1_0.jms.impl.MessageProducerImpl.<init>(MessageProducerImpl.java:86)
... 3 more
Caused by: java.util.concurrent.TimeoutException
at org.apache.qpid.amqp_1_0.transport.ConnectionEndpoint.waitUntil(ConnectionEndpoint.java:1232)
at org.apache.qpid.amqp_1_0.transport.ConnectionEndpoint.waitUntil(ConnectionEndpoint.java:1214)
at org.apache.qpid.amqp_1_0.transport.SessionEndpoint.waitUntil(SessionEndpoint.java:681)
at org.apache.qpid.amqp_1_0.transport.LinkEndpoint.waitUntil(LinkEndpoint.java:355)
at org.apache.qpid.amqp_1_0.client.Sender.<init>(Sender.java:167)
... 11 more
Any help will be greatly appreciated.