Amit,

On 10/16/15 3:44 PM, Amit Lonkar wrote:
> Thanks Chris
> 
> Tried two scenarios
> 
> 1. Removed any tomcat-*.jar files from webapp/WEB-INF/lib folder. Also moved 
> ant-1.9.6.jar from webapp/WEB-INF/lib to catalina/lib. All works fine now.
> 
> 2. Removed any tomcat-*.jar files from webapp/WEB-INF/lib folder, but this 
> time left the  ant-1.9.6.jar in webapp/WEB-INF/lib. Got the following error. 
> Since Ant is not shipped with tomcat we are bundling it with our application. 
> Any reason why Ant needs to be in tomcat/lib folder?
> 
> type Exception report
> 
> message Servlet execution threw an exception
> 
> description The server encountered an internal error that prevented it from 
> fulfilling this request.
> 
> exception
> 
> javax.servlet.ServletException: Servlet execution threw an exception
>       org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
> root cause
> 
> java.lang.NoClassDefFoundError: org/apache/tools/ant/Task
>       java.lang.ClassLoader.defineClass1(Native Method)
>       java.lang.ClassLoader.defineClass(ClassLoader.java:760)
>       java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
>       java.net.URLClassLoader.defineClass(URLClassLoader.java:467)
>       java.net.URLClassLoader.access$100(URLClassLoader.java:73)
>       java.net.URLClassLoader$1.run(URLClassLoader.java:368)
>       java.net.URLClassLoader$1.run(URLClassLoader.java:362)

It's all going to come down to which ClassLoader is in effect then the
thread tries to load that class. Was that the full stack trace? That
looks like an anonymous permission-executor class to elevate privileges
for a certain operation.

-chris

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org

Reply via email to