我自己的 grails 托管
如果我有一台带有 tomcat 等的服务器。我怎样才能只为自己创建良好的托管。我的意思是我是否可以在一台tomcat 上拥有多个站点?在将新代码上传到 tomcat 上的特定应用程序时,是否可以创建稳定的环境,而无需重新启动整个服务器?我只知道,如果有人更改其中一个应用程序上的某些代码,那么使用经典 Java 几乎不可能拥有多个 24x7 在线的站点。这并不像 ruby on Rails 那么容易,对吗?
if i have a server machine with tomcat etc. How could i create well hosting for myself only. I mean if i would have several sites on one tomcat? If it possible to create stable environment with that without needing to restarting whole server when uploading new code to particular application on the tomcat? I just know that it is almost impossible with classic Java to have several sites which would be online 24x7 if someone changes some code on one of the application. It is not so easy as with ruby on rails right?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
错误的。实际上,在 Tomcat 中重新部署正在运行的应用程序非常容易 ,其他应用程序不受影响。
主要问题是应用程序中的类加载器泄漏,这最终可能导致
OutOfMemoryError
并需要重新启动。Wrong. It's actually quite easy to redeploy a running application in Tomcat, and other applications are not affected.
The main problem with this is classloader leaks in applications, which can eventually lead to an
OutOfMemoryError
and require a restart.使用 Grails,您的热部署能力将受到 Perm Gen 设置的限制。我让 Hudson 自动构建一个稳定了数周的环境 - 我使用的永久代设置是:
With Grails your ability to hot deploy will be gated by your Perm Gen settings. I have Hudson auto-building to an environment that has been stable for weeks - the perm gen settings I use are: