qpid-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Robbie Gemmell <robbie.gemm...@gmail.com>
Subject Re: javax.jms.JMSException: Cannot send to a non-connected transport
Date Thu, 11 May 2017 14:44:09 GMT
Its saying the connection failed. One thing that I can think of is
that maybe you are using an older version of the client, which doesnt
pick up changes to the javax.net.ssl.* system properties on the fly,
https://issues.apache.org/jira/browse/QPIDJMS-253, in which case you
can try setting when loading the app, or use the URI config.

On 11 May 2017 at 15:30, jeunii <ijunaidsubhani@gmail.com> wrote:
> I am using the `qpid-jms-client.jar` library to form a connection with a
> broker.
>
> My code is ::
>
>     Properties properties = new Properties();
>     properties.load(this.getClass().getResourceAsStream("jndi.properties"));
>     Context context = new InitialContext(properties);
>
>     System.setProperty("javax.net.ssl.trustStore",
> "C:/Users/xxxxx/qpid.jks");
>     System.setProperty("javax.net.ssl.trustStorePassword", "test123");
>
>     ConnectionFactory factory = (ConnectionFactory)
> context.lookup("myFactoryLookup");
>     Destination queue = (Destination) context.lookup("myQueueLookup");
>     Connection connection = factory.createConnection("<my-username>",
> "<my-password>");
>     connection.setExceptionListener(new MyExceptionListener());
>     connection.start();
>
> My jndi.properties file is ::
>
>
> java.naming.factory.initial=org.apache.qpid.jms.jndi.JmsInitialContextFactory
>     connectionfactory.myFactoryLookup=amqps://esesslx0100.se:9443
>     queue.myQueueLookup=emft_input
>     topic.myTopicLookup=topic
>     destination.topicExchange=amq.topic
>     jms.user=test
>
> Now the above code gives me the ERROR ::
>
>     Connection ExceptionListener fired, exiting.
>     javax.jms.JMSException: Cannot send to a non-connected transport.
>         at
> org.apache.qpid.jms.exceptions.JmsExceptionSupport.create(JmsExceptionSupport.java:66)
>         at
> org.apache.qpid.jms.exceptions.JmsExceptionSupport.create(JmsExceptionSupport.java:88)
>         at
> org.apache.qpid.jms.JmsConnection.onAsyncException(JmsConnection.java:1188)
>         at
> org.apache.qpid.jms.JmsConnection.onConnectionFailure(JmsConnection.java:1104)
>         at
> org.apache.qpid.jms.provider.amqp.AmqpProvider.fireProviderException(AmqpProvider.java:847)
>         at
> org.apache.qpid.jms.provider.amqp.AmqpProvider.pumpToProtonTransport(AmqpProvider.java:820)
>         at
> org.apache.qpid.jms.provider.amqp.AmqpProvider.access$300(AmqpProvider.java:90)
>         at
> org.apache.qpid.jms.provider.amqp.AmqpProvider$16.run(AmqpProvider.java:683)
>         at
> java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
>         at java.util.concurrent.FutureTask.run(FutureTask.java:266)
>         at
> java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180)
>         at
> java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293)
>         at
> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
>         at
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
>         at java.lang.Thread.run(Thread.java:745)
>     Caused by: java.io.IOException: Cannot send to a non-connected
> transport.
>         at
> org.apache.qpid.jms.transports.netty.NettyTcpTransport.checkConnected(NettyTcpTransport.java:279)
>         at
> org.apache.qpid.jms.transports.netty.NettyTcpTransport.allocateSendBuffer(NettyTcpTransport.java:176)
>         at
> org.apache.qpid.jms.provider.amqp.AmqpProvider.pumpToProtonTransport(AmqpProvider.java:806)
>         ... 9 more
>
> Since the broker is configures with SaSL, I am also providing my username
> and password. I am currently unaware of why this ERROR occurs. Ive looked
> around on the internet but there is no clear explanation as to why it would
> occur with qpid. Any ideas why this ERROR occurs ?
>
> My trustStore file is correct since I have verifies SSL connectivity using
> it.
>
>
>
> --
> View this message in context: http://qpid.2158936.n2.nabble.com/javax-jms-JMSException-Cannot-send-to-a-non-connected-transport-tp7663061.html
> Sent from the Apache Qpid users mailing list archive at Nabble.com.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@qpid.apache.org
> For additional commands, e-mail: users-help@qpid.apache.org
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@qpid.apache.org
For additional commands, e-mail: users-help@qpid.apache.org


Mime
View raw message