NoClassDefFoundError (Digester) with Tomcat and MyFaces

青春壹個敷衍的年華 提交于 2019-12-01 01:44:35
Caused by: java.lang.ClassNotFoundException: org.apache.commons.digester.Digester

This just tells you that the mentioned class is missing in the runtime classpath. As the package name hints, it's Apache Commons Digester which is available at http://commons.apache.org/digester. If you download the JAR file and drop it in one of the paths covered by the webapp's runtime classpath, such as /WEB-INF/lib, then this problem should disappear.

I had the same problem. Webapp and Tomcat in Eclipse ran nice, then eclipse freezed; I had to kill it with TaskManager. However when I restarted tomcat, above error java.lang.NoClassDefFoundError: org/apache/commons/digester/Digester appeared.

It did not make sense because the webapp ran nicely before. I solved it by cleaning the eclipse tomcat webapp directory.

  1. Go to the Servers tab -> Right click on your webapp -> Clean Module directory.
  2. Go to the Servers tab -> Right click on used Tomcat instance -> Clean...

After that the error disappeared and the webapp ran again like before.

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!