Resin 3.1 Upgrade

From Resin 3.0

Revision as of 10:27, 19 February 2009 by Ferg (Talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search
  • Use java -jar lib/resin.jar start instead of
  • resin.conf <cluster> and <server> reorganization
  • jvm-arg arg configuration




To convert a Resin 3.0 config to Resin 3.1 or later, use the following steps:

  1. change <server> to <cluster>
  2. change <srun> to <server>
  3. put any <http> inside the <server> or <server-default>
  4. put JVM arguments inside <jvm-arg> inside <server>
  5. add explicit <host> or <web-app> for any default web-app or host
  6. put default configuration in <web-app-default>, <host-default>, or <server-default> as appropriate
  7. if you use multiple resin.conf for 3.0, merge them into a single resin.conf with separate <cluster> items.
  8. change any scripts calling to call java -jar lib/resin.jar start

cluster and server

In Resin 3.1, we've adopted a consistent definition of the following terms to reduce ambiguity:

  • server - a single JVM instance
  • machine - a physical (or virtualized) machine, i.e. a single operating system copy
  • cluster - a set of identically-configured servers. The jvm-args may differ, but the content served is identical

The Resin 3.1 configuration matches these definitions and follows a strict hierarchy:

  • <resin> - domain containing of all clusters
  • <cluster> - a collection of identical serveres, e.g. load-balancer tier vs app-tier vs JMS queue tier
  • <host> - a virtual host
  • <web-app> - a web-application

Even if you have a single server, that server belongs to a <cluster> with one server.

jvm-arg configuration in Resin 3.1

Resin 3.1 configures JVM arguments in the resin.conf using a <jvm-arg> so all configuration can be in one place, instead of split between the resin.conf and any shell scripts.

The <jvm-arg> is contained in the <server> tag because the JVM arguments apply to a single JVM, i.e. a Resin server.

A sample configuration might look like:

<resin xmlns="">
   <cluster id="app">
      <server id="a" port="6800">
         <http port="8080"/>


     <host id=">

The ${HEAP} expression is a JSP EL expression that uses a -DHEAP=128 passed to the command-line, like

 resin-3.1.x> java -DHEAP=128 -jar lib/resin.jar start

watchdog vs

Resin 3.1 replaces the old with a Java watchdog process. The watchdog reads the resin.conf and uses the <server> and <jvm-arg> to start the child Resin process.

To start the watchdog (and Resin), use

 resin-3.1.x> java -jar lib/resin.jar start

To stop it, use

 resin-3.1.x> java -jar lib/resin.jar stop
Personal tools