Hi,
I have downloaded a sample jms program from the below url and try to execute it in my system.But, it shows the below error.Can any one know how to execute the Jms programs in the system.
http://download.oracle.com/javaee/1.4/tutorial/examples/jms/simple/src/SimpleProducer.java
Error:
package javax.jms does not exist
import javax.jms.*;
^
SimpleProducer.java:90: cannot find symbol
symbol : class ConnectionFactory
location: class SimpleProducer
ConnectionFactory connectionFactory = null;
^
SimpleProducer.java:91: cannot find symbol
symbol : class Destination
location: class SimpleProducer
Destination dest = null;
^
SimpleProducer.java:94: cannot find symbol
symbol : class ConnectionFactory
location: class SimpleProducer
connectionFactory = (ConnectionFactory) jndiContext.lookup(
^
SimpleProducer.java:96: cannot find symbol
symbol : class Destination
location: class SimpleProducer
dest = (Destination) jndiContext.lookup(destName);
^
SimpleProducer.java:112: cannot find symbol
symbol : class Connection
location: class SimpleProducer
Connection connection = null;
^
SimpleProducer.java:113: cannot find symbol
symbol : class MessageProducer
location: class SimpleProducer
MessageProducer producer = null;
^
SimpleProducer.java:118: cannot find symbol
symbol : class Session
location: class SimpleProducer
Session session =
^
SimpleProducer.java:119: cannot find symbol
symbol : variable Session
location: class SimpleProducer
connection.createSession(false, Session.AUTO_ACKNOWLEDGE);
^
SimpleProducer.java:122: cannot find symbol
symbol : class TextMessage
location: class SimpleProducer
TextMessage message = session.createTextMessage();
^
SimpleProducer.java:135: cannot find symbol
symbol : class JMSException
location: class SimpleProducer
} catch (JMSException e) {
^
SimpleProducer.java:141: cannot find symbol
symbol : class JMSException
location: class SimpleProducer
} catch (JMSException e) {
^
Thank you,
With Regards,
Prem.