Eclipse:Apache Tomcat 在我重新启动 Eclipse 之前不会更新我的项目
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/10250861/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Eclipse: Apache Tomcat doesn't update my project until I restarted Eclipse
提问by hqt
I have tested my a simple form.html
. I change something on here, and right click on project, run on server. My server (Apache Tomcat) will run my project.
我已经测试了我的一个简单的form.html
. 我在这里更改了一些东西,然后右键单击项目,在服务器上运行。我的服务器(Apache Tomcat)将运行我的项目。
But, I don't know why, it rarely update my project. (mean form.html
no change !!!) until I restart eclipse and run project again.
但是,我不知道为什么,它很少更新我的项目。(意味着form.html
没有变化!!!)直到我重新启动 eclipse 并再次运行项目。
Maybe the strange thing is : no message box appear asked me: "Do you want to restart server" like before. But I have config in Eclipse that "always restarted server when required" to "always". But, after I change something like some space in form.html
, I just see that Eclipse save and run project. (not stop and start server again). Maybe the problem here !!!
也许奇怪的是:没有消息框出现问我:“你想重新启动服务器吗”像以前一样。但是我在 Eclipse 中的配置“总是在需要时重新启动服务器”到“总是”。但是,在我更改了一些空间后form.html
,我只看到 Eclipse 保存并运行项目。(不是停止并再次启动服务器)。可能是这里的问题!!!
(before that, I have clicked that not restart server, and remember this action), but I don't know how to config again for this
(在此之前,我点击了不重启服务器,并记住了这个动作),但我不知道如何再次为此进行配置
Thanks :)
谢谢 :)
回答by Stefan
Open the "Server" view and doubleclick on your server. Check the server location and deploy path. Open the publish tab and make sure "automatically publish when resource changes" is selected. Static resources will be hot deployed and there's no need to restart the server.
打开“服务器”视图并双击您的服务器。检查服务器位置和部署路径。打开发布选项卡并确保选择“资源更改时自动发布”。静态资源将被热部署,无需重启服务器。
You can always republish resources by clicking your servers name in the Server view and then clicking the icon to the very right (in the header), Ctrl+Alt+P.
您始终可以通过在“服务器”视图中单击您的服务器名称,然后单击最右侧(在标题中)的图标Ctrl+ Alt+来重新发布资源P。
The "restart server" function can be modified here: window > prefereces > server > launching.
“重启服务器”功能可以在这里修改:window>preferencees>server>launch。