Resin 3.1.0 is now available.  Keep in mind that 3.1.x is a  
development branch.  3.1.1 will have new features as well as bug  
fixes, so it is possible that 3.1.1 may introduce new bugs.

Main changes in 3.1.0:
   Requires JDK 1.5
   Servlet for JavaEE 1.5
   JSP for JavaEE 1.5
   Amber progress (almost, but not quite passing JPA)
   resin.conf refactoring for improved cluster configuration
   watchdog/startup changes
   web services configuration (as servlet)
   Quercus updates for PHP 6 (i18n), Java reflection

I) Watchdog/startup changes:

The most visible change is the Resin startup, particularly on Unix.    
The is now gone, replaced by a Java watchdog process.  The  
unix command-line startup is:

   unix> java -jar resin-3.1.0/lib/resin.jar start

Or, for foreground, development work, just

   unix> java -jar resin-3.1.0/lib/resin.jar

For different configuration files and servers, use

   unix> java -jar lib/resin.jar -conf conf/myconfig.conf -server app- 
a start

Windows users can also use the new startup, but can still use the old  

Because the watchdog process is in Java, JDK command-line arguments  
now belong in the resin.conf.  This will be nice, since all the  
relevant configuration will now be in resin.conf.

II) resin.conf clustering changes.

We've reorganized the resin.conf to better handle multiple clusters.   
The most important use is for web-tier and app-tier load-balancing.   
Now, both the web-tier and the app-tier fit into the same resin.conf.

The old 3.1.0 syntax is still available as backward compatibility,  
but we encourage people to upgrade.

The basic structure is:

   <resin xmlns="";>
     <cluster id="app-tier">
          <!-- common configuration for all servers in a cluster,  
like thread-max -->
          <http address="*" port="8080"/>

      <!-- server replaces srun -->
      <server id="app-a" address="" port="6800"/>

       <host id="">
         <!-- usual virtual host configuration -->

III) web services

Web services can now be configured as servlets (this is part of the  
Servlet 2.5 spec).  If the servlet-class implements @WebService, it  
will be treated as a web-service.  The class does not need to  
implement Servlet.  The lifecycle is the same as for a servlet, i.e.  
only a single, multithreaded instance (no pooling).

Resin allows a choice of protocols, including Hessian, Burlap, and  
REST.  So the configuration might look like:

<servlet-mapping url-pattern="/hello/*"
   <protocol type="hessian">

IV) JSP and Servlet for JavaEE 5

See the specs. :)

The main new capabilities are @Resource injection and capabilities  
for the new JSF (i.e. "%{foo}").

The @Resource injection is very nice.  It removes the requirement for  
most JNDI lookup, e.g.

public class MyServlet ... {
   private DataSource _dataSource;

Resin will inject the DataSource into the servlet before it calls the  
init() method.

V) @Resource for java.util.concurrent.Executor

In Resin you can use the @Resource to get access to Resin's thread  
pool for Executor-launched threads.  This means you can launch short- 
lived threads using Resin's thread pool.

However, you still need to be careful about lifecycle issues.  We  
haven't yet implemented an ExecutorService which would let Resin stop  
the thread on web-app restart automatically.  So you still need to  
have the destroy() method stop the thread.

class MyServlet {
   private Executor _executor;

   private void foo()
     _executor.execute(new MyRunnableTask());

VI) Resin 3.1.1 roadmap

The roadmap always changes, so take this as a rough guideline of  
intent.  We think the following will be ready for 3.1.1 (in about 12  
weeks or so)

   more of EJB 3.0 (I'm not sure we'll get it done by 3.1.1)
   Quercus integration as scripting language for packages like  
Spring, Grails, etc.

We're aiming on JavaEE 5 by May.  I think that's probably optimistic,  
but it's our current target.

Share and Enjoy!

resin-interest mailing list

Reply via email to