I have a spring web application which I am trying to deploy on tomcat 7. I got following error on tomcat 7 start-up:
Caused by:
java.lang.ClassNotFoundException: javax.jms.JMSContext
This is because tomcat could not find javaee-api-7.0.jar
which is present in my application's WEB-INF/lib
folder. However, if I copy this to tomcat/lib
, error is fixed and tomcat can load the class.
But I don't want to copy any additional jars to tomcat/lib. Can someone help here so that tomcat can find above jar in application's lib. Am I missing any classpath handler entries? I have not added any explicitly.
spring-jms
thejavax-jms
dependency is markedprovided
and hence needs to be added by the container. – Judaic