我在struts2应用程序中添加了Spring Boot应用程序jar作为依赖,但是struts 2无法理解它的注解。我只是想清除 Spring Boot jar 包含其各自的 lib 文件夹。在这种情况下,struts2 应用程序可以工作,但由于注释不起作用,因此逻辑失败。
当我在struts2项目中添加Spring Boot依赖时,它能够理解Spring Boot注解,但是struts2项目停止工作并抛出错误:
com.ibm.ws.webcontainer.webapp.WebApp logServletError SRVE0293E:
[Servlet Error]-[ServletNameNotFound]:
java.lang.NoClassDefFoundError:
servlet.filters.RequestFilter (initialization failure)
因此应用程序无法启动。
为了使 struts2 应用程序运行,我尝试在 Spring Boot jar 和 struts2 应用程序中同时添加 struts2-spring-plugin。
没有任何效果,struts2 应用程序仍然无法运行。