Posted: Tue Oct 02, 2007 12:56 am Post subject: JmsTemplate Spring and queueManagerName
Newbie
Joined: 31 Aug 2007 Posts: 7
Hi,
I'm using WAS6.1 with Spring.
I declare a ressource jndi for the QueueconnectionFactory, and I work with the sping class JmsTemplate.
In a class java, I would like to retrieve the QueueManagerName of the QueueconnectionFacotry.
When I cast mu connextionFactory to a MqQueueconnectionFactory, I'v got a ClassCastException.
Joined: 25 May 2002 Posts: 664 Location: South East London
Dump the connectionFactory class to see what it acually is, e.g.
System.out.println(connectionFactory.getClass().getName());
It's probably some internal spring proxy class and so you will be unable to cast down to the specific type of connection factory. You may want to inject the connection factory as a seperate property of the bean and cast this.
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum