It may be possible to deploy a web application to a live server
without interruption to service if certain conditions are met.
- The session objects for your users are being persisted.
- The usage of session scoped objects between the old version and the new is compatible.
- The usage of application scoped objects between the old version and the new is compatible.
- Database schema changes are not required.
Resin allows you to have a backup instance running. The idea is that
this backup instance of Resin takes over if your primary Resin
instance goes down.
If you are using a load balancer to distribute your load to multiple
primary servers, each primary server has a backup server.
You can use this feature to deploy to a live server without
interruption of service.
- shutdown primary server(s) (backup server(s) takes over)
- deploy new war to primary server(s)
- start primary server(s). As soon as the primary server starts,
the user will be using the new version of the application.
- deploy new war to backup server(s)
class com.caucho.jsp.JspPrecompileListener is a ServletContextListener
that compiles jsp files when the web-app starts. It is activated using the
<listener> Servlet configuration tag in web.xml.
The following configuration causes Resin to compile all files in the web-app
that have an extension of .jsp or .jspx when the application first starts.
WEB-INF/web.xml
<web-app xmlns="http://caucho.com/ns/resin">
<listener>
<listener-class>com.caucho.jsp.JspPrecompileListener</listener-class>
<init>
<extension>jsp</extension>
<extension>jspx</extension>
</init>
</listener>
</web-app>
|
It can also be configured in resin.conf.
resin.conf
<web-app id="foo" document-directory="/usr/local/webapps/foo">
<listener>
<listener-class>com.caucho.jsp.JspPrecompileListener</listener-class>
<init>
<extension>jsp</extension>
<extension>jspx</extension>
<extension>xtp</extension>
</init>
</listener>
</web-app>
|
Copyright © 1998-2003 Caucho Technology, Inc. All rights reserved.
Resin® is a registered trademark,
and HardCoretm and Quercustm are trademarks of Caucho Technology, Inc. |  |
|