resin 4.0.16 release notes
4.0.16 has primarily been a bug-fix release.
The health check system has been enhanced, allowing for more control of Resin restarts and logging. The configuration is still in progress, and can be seen in the conf/health.xml file. The health configuration follows the same pattern as the rewrite rules. Each action has a set of optional predicates that tell when the action should occur. <cluster xmlns="http://caucho.com/ns/resin" xmlns:health="urn:java:com.caucho.health"> <health:CpuHealthCheck> <warningThreshold>95</warningThreshold> <criticalThreshold>99</criticalThreshold> </health:CpuHealthCheck> <health:DumpThreads> <health:IfCriticalRechecked time="2m" healthCheck="${cpuHealthCheck}"/> </health:DumpThreads> </cluster> In the example, the <health:IfCriticalRechecked> predicate is true if the CpuHealthCheck returns a critical value for 2 minutes. This will avoid log a thread dump for a temporary CPU spike. Resin 4.0.16 has implemented draft-6 of the web socket protocol. A Resin WebSocket Tutorial is available. Resin's API is based on the stream model of the Servlet API, using OutputStream and PrintWriter to send messages and InputStream and Reader to receive messages. package com.caucho.servlet; public interface WebSocketContext { public OutputStream startBinaryMessage() throws IOException; public PrintWriter startTextMessage() throws IOException; public void setTimeout(long timeout); public long getTimeout(); public void close(); public void disconnect(); } package com.caucho.servlet; public interface WebSocketListener { public void onStart(WebSocketContext context) throws IOException; public void onReadBinary(WebSocketContext context, InputStream is) throws IOException; public void onReadText(WebSocketContext context, Reader is) throws IOException; public void onClose(WebSocketContext context) throws IOException; public void onDisconnect(WebSocketContext context) throws IOException; public void onTimeout(WebSocketContext context) throws IOException; } The HMTP/JMTP messaging APIs continue to change as we work on simplifying the model. Resin uses HMTP/BAM as its internal clustered messaging framework. We now have 5 base classes:
The rewrite-dispatch order has been normalized. This should be invisible for most users, Resin now has a better-defined order for dispatching. All requests now go through the following order (basically a servlet filter chain order.) security (checked first) rewrite-dispatch filters servlet Since dispatch actions like <resin:LoadBalance> and <resin:HttpProxy> are rewrite-dispatch rules, this means that security will be applied, but servlet filters will not be applied. The proxy cache has been refactored internally to better handle exceptions and disconnects while filling the cache. The decision to make a request a cache-fill thread now happens at the top filter call, which allows the cleanup logic to be a simple "finally" block. Resin's authenticators now support LDAP-style {SSHA} passwords for all the built-in authenticators, or anyone extending from AbstractAuthenticator. <web-app xmlns="http://caucho.com/ns/resin" xmlns:resin="urn:java:com.caucho.resin"> <resin:XmlAuthenticator> <user name='harry' password='{SSHA}Vug/pmSPPOTh/dCG2GpDE6BIE+1zYWx0'/> <user name='draco' password='{SSHA}H9STJXP1NwWBy1VIL+6cVQPEMtxzbmFrZQ=='/> </resin:XmlAuthenticator> </web-app> The load-balance and cluster TCP socket pools are now split and using different timeouts. The cluster socket pool is used for HMTP/BAM messages for heartbeat, dist-cache, repository, etc. The load balance pool is used for <resin:LoadBalance>, <resin:HttpProxy> and <resin:FastCgiProxy.
|