Necessary jar files for basic sturts 2 application

丶灬走出姿态 提交于 2020-01-01 22:15:21

问题


I am just new to Sturts 2 Web Application Development. I started with basic hello world Sturt application. Its working fine, but m still wondering that what jar files are needed for what kind of Sturts 2 application, or at least for a basic sturt application.


回答1:


Now that have a working Java web application, lets add the minimal required Struts 2 framework Jar files to our web application's class path. And copy these Jar files from the lib folder of the Struts 2 download to the WEB-INF/lib folder in our web application.

Find and copy to WEB-INF\lib these files (note X.X.X.X.jar refers to the version number):

  1. commons-fileupload-X.X.X.jar
  2. commons-io-X.X.X.jar
  3. commons-logging-X.X.X.jar
  4. commons-logging-api.X.X.jar
  5. freemarker-X.X.X.jar
  6. ognl-X.X.X.jar
  7. struts2-core-X.X.X.X.jar
  8. xwork-core-X.X.X.jar
  9. javassist-3.7.ga.jar (new for Struts versions 2.2.1 and higher)

You can see from the above that the Struts 2 core jar depends on several other artifacts. As we add additional Struts 2 features in future tutorials, we'll need to add additional Struts 2 jar files and other transitive dependencies.

use this link




回答2:


you need to add one more jar file xwork2.jar I think this is important jar.



来源:https://stackoverflow.com/questions/22250153/necessary-jar-files-for-basic-sturts-2-application

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