Resin 3.1.x
Resin 3.1.x is a development branch. New capabilities will be added along with bug fixes for future versions of the Resin 3.1.x branch.
Deployments which need a Resin version with only bug fixes should use the Resin 3.0.x branch.
Servlet 2.5
Resin 3.1 adds Servlet 2.5 support. The Servlet 2.5 specification adds annotation-based injection to servlets, filters, and listeners. Servlets can now mark a field as a @Resource and Resin will assign the configured database, bean, or service to the field, avoiding the need for a JNDI lookup.
package example;
import javax.annotation.Resource;
import javax.servlet.*;
import javax.sql.*;
public class MyServlet extends GenericServlet {
@Resource(name="jdbc/mysql")
private DataSource _database;
public void service(ServletRequest req, ServletResponse res)
{
...
}
}
Amber capabilities
With Resin 3.1, the JPA features have been reviewed. Amber now provides a near to complete and stable implementation of the JPA specification.
JPA queries are fully supported, including queries with parameters, named queries, and subqueries. The javax.persistence.Query API is also supported, including date/time (temporal) data types.
Embedded properties and optimistic-locking with version fields have been added to Amber in Resin 3.1. Also, inheritance combined with many-to-one, one-to-many, one-to-one, and many-to-many relationships have been reviewed and are now totally stable following the final release of the JPA specification.
Finally, an object relational mapping file (orm.xml) can now be merged together with annotations, when present. In other words, with Resin 3.1, the set of JPA features supported by Amber is near to complete, i.e., only a few unusual features will be added to the next release.
watchdog/startup changes
Resin 3.1 now uses a Java watchdog process to manage Resin instances for reliability. Like the older 3.0 wrapper.pl, it detects if the instance has stopped and restarts it automatically.
Because the watchdog is now a Java process, the Resin start and stop can now use a Java -jar command:
unix> java -jar $RESIN_HOME/lib/resin.jar -server a start
Also, because the Resin instance is started from Java itself, the JVM command-line arguments must now be specified in the resin.conf.
JVM command-line arguments
With Resin 3.1, JVM command-line arguments are specified in the resin.conf. The watchdog JVM will read the resin.conf, select the proper <server>, and apply the server's arguments. As usual, the <server-default> tag can provide common defaults.
-Xmx1024m
-Xss1m
-verbosegc
http://www.wujianrong.com/mt-tb.cgi/4574