使用 Spring-MVC 降低 Java Web 应用程序中的部署频率
有没有一种简单的方法可以将“服务层”与 Web 层分开部署,这样我就可以减少每周打包、构建和部署整个 WAR 文件的次数?
我主要使用 Tomcat,但我希望有一些对 Java Web 服务器更通用的东西。
Is there a simple way to have your "Service Layer" deployed separately from your web layer, so that I can reduce the number of times per week that I have to, package, build and deploy the entire WAR file?
I'm using Tomcat mostly, but I'm hoping for something more generic to Java web servers.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
![扫码二维码加入Web技术交流群](/public/img/jiaqun_03.jpg)
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
您可以将“服务层”移动到第二个应用程序,并让前端应用程序使用某种远程技术与“服务”进行通信。
Spring 远程处理(又名HttpInvoker) 使其使用起来非常简单。
You could move your "service layer" to a second application and have the front-end application communicate with the "services" using some sort of remoting technology.
Spring Remoting (a.k.a. HttpInvoker) makes this very simple to use.
如果包-构建-部署过程是必要的,但足够重量级,以至于您希望最小化或避免它,您也可以考虑使该过程更容易、更快或更自动化。
If the package-build-deploy process is necessary, but heavyweight enough that you want to minimize or avoid it, you might also consider making that process easier, faster, or more automated.