• Post Reply Bookmark Topic Watch Topic
  • New Topic

exception in messaging application

 
James Clarke
Ranch Hand
Posts: 148
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I wrote a simple application that sends and receives messages. I am using netbeans IDE and the Sun application server. I am getting the below exception at this code in the application:

ConnectionFactory queueConnectionFactory = (ConnectionFactory)
jndiContext.lookup("QueueConnectionFactory3");

Exception:

Queue name is testjmsgateway.queue
Jul 4, 2006 10:49:33 PM com.sun.enterprise.naming.SerialContext lookup
SEVERE: NAM0004: Exception during name lookup : {0}
java.lang.InstantiationException: javax.jms.ConnectionFactory
at java.lang.Class.newInstance0(Class.java:335)
JNDI API lookup failed: javax.naming.CommunicationException: serial context communication ex [Root exception is java.lang.InstantiationException: javax.jms.ConnectionFactory]
at java.lang.Class.newInstance(Class.java:303)
at javax.naming.spi.NamingManager.getObjectFactoryFromReference(NamingManager.java:146)
at javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:302)
at com.sun.enterprise.naming.SerialContext.lookup(SerialContext.java:314)
at javax.naming.InitialContext.lookup(InitialContext.java:351)
at gateway.SimpleQueueSender.main(SimpleQueueSender.java:105)
Java Result: 1
debug:
BUILD SUCCESSFUL (total time: 27 seconds)

Anyone know what could be causing this ?

thanks,

James
[ July 04, 2006: Message edited by: James Clarke ]
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!