Where are the generated JSP class files located?

2019-01-12 04:37发布

I am using Tomcat 7.1 and Eclipse Indigo to develop a Java Web Application. I just want to ask if anybody knows where the JSP translated files (the java files) are stored? Its often i receive exceptions indicating the jsp java file line, but if i can not see the file it is more difficult to correct the bug.

标签: java eclipse jsp
3条回答
smile是对你的礼貌
2楼-- · 2019-01-12 05:00

Doubleclick the Tomcat entry in Servers tab in Eclipse. You'll see something like this in Server Locations section:

enter image description here

If you haven't changed the server path and it thus defaults to Eclipse's workspace metadata, then the Tomcat's /work directory is not in Tomcat's own installation folder, but in the path as shown in the above screenshot.


Unrelated to the concrete problem, if you adhere the JSP coding recommendations and you avoid Java code in JSP altogether, then debugging will be so much easier, along with a lot of other advantages.

查看更多
Deceive 欺骗
3楼-- · 2019-01-12 05:02

you can find the jsp compailed java classes in your workspace: And the path is: workspace.metadata.plugins\org.eclipse.wst.server.core\tmp0\work\Catalina\localhost\auctuus\org\apache\jsp\jsp\gbp\settings

查看更多
趁早两清
4楼-- · 2019-01-12 05:07

The JSP translated files are stored (in Tomcat) in /work/Catalina/localhost/[your_app_context]/org/apache/jsp/.

Should check in other containers or web servers.

查看更多
登录 后发表回答