当我启动链接到我的 Java EE 项目的 Tomcat 服务器时,出现下面列出的错误。另外两个人在 Eclipse/Tomcat/Java 中使用相同的存储库并且没有任何问题。它创建了我的包层次结构,但类丢失了。 Tomcat开发了我的WEB-INF/classes/com文件夹,但是里面的内容都是空的。谁能帮我这个?谢谢。
SEVERE: Context initialization failed org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.springframework.web.servlet.mvc.annotation.DefaultAnnotationHandlerMapping#0' defined in ServletContext resource [/WEB-INF/LightStanza-servlet.xml]: Initialization of bean failed; nested exception is org.springframework.beans.factory.CannotLoadBeanClassException: Cannot find class [com.lightfoundryllc.lightstanza.login.LoginValidator] for bean with name 'loginValidator' defined in ServletContext resource [/WEB-INF/LightStanza-servlet.xml]; nested exception is java.lang.ClassNotFoundException: com.lightfoundryllc.lightstanza.login.LoginValidator
最佳答案
感谢您的帮助。我为 TOMCAT_HOME 和 PATH 设置了我的环境变量,现在一切似乎都正常了:)。
关于java - 为什么 Eclipse 不编译我的 Web 应用程序?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/4951966/