Look at lines 1124-1128 of the 5.8.0 version of FailoverTransport.java ( http://grepcode.com/file/repo1.maven.org/maven2/org.apache.activemq/activemq-client/5.8.0/org/apache/activemq/transport/failover/FailoverTransport.java#FailoverTransport.propagateFailureToExceptionListener%28java.lang.Exception%29) for an explanation of how a SecurityException could be wrapped and rethrown as an IOException.
But more generally, why are you going down this particular rabbithole? Why exactly do you need to reproduce a security exception? Why is doing that critical to what you're trying to do, which is to find out when you're disconnected from the broker and letting your client know that? And why can't you just write the code to implement TransportListener so it'll work no matter what kind of exception is thrown, without having to figure out how to produce each possible exception? It seems like you're making a lot of unnecessary extra work for yourself, and for the people you're asking to help you in their free time... On Tue, Oct 7, 2014 at 7:48 AM, bansalp <bpradee...@gmail.com> wrote: > Hi am unable to reproduce a security exception? Can you please help me with > this? > > > > > > -- > View this message in context: > http://activemq.2283324.n4.nabble.com/Question-on-TransportListener-tp4686170p4686199.html > Sent from the ActiveMQ - User mailing list archive at Nabble.com. >