Author Archives: Sean Wiley

Caucho Newsletter September 2018

Caucho Newsletter June 2018

Caucho Newsletter February 2018


Caucho Newsletter November 2017

Caucho Newsletter September 2017


Caucho Newsletter July 2017

 

paradise-sky.jpg  

          main caucho logo 3
 
  
           New Releases, Partnerships and Success Stories!

          Resin Pro has the advantages of being lightweight and fast. Thanks to the fast and precise support of Xest Information Technology, Caucho’s Korean partner, we have been able to create our current Resin operating environment. I've used WebLogic, Jeus, JBoss and other app servers. Resin is the most satisfying of all of them.” 

– Kyobobooks IT Team Leader Seo-ho, Cho (Kyobobooks is a leading bookstore in South Korea, with 35 bookstores and a mobile site that services 160,000 users/day).
 

Newsletter at a GlanceSun_with_Sunglasses_Transparent_Picture.png

  • Resin 4.0.52 and 4.0.53

  • Case Study – ChosunILBO migration from WebLogic to Resin

  • Caucho Partners with NTT Data Intramart Figtree Innovation Centre in Sydney, Australia

  • ​Cool Resin tip – dispatch rule

 

Resin Updates
 

A lot of engineering work has gone into the latest release of Resin.  Users see a notable growth in performance and long-term stability. Good news! We have less than 10 open bug reports, including feature requests.

 

Bug fixes in the new versions include:

 

Resin – 4.0.52

==============

- 0006051: Diffie-Hellman group vulnerability

- 0006041:  com.caucho.jmx.MBeanView does not match wildcard queries

- 0006037:  ByteCodeParser with jdk8 constants

- 0006042:  JSP and PHP is not reloaded after modification

- 0006045: issue with mmap read

- 0006033:  access.log rotation issue

- 0005920:  access log not archived intermittently

- 0006049:  indirection through jndi:/server/<path> removes server

- 0006047:  resin-data db corruption creates large log file, prevents restart

- 0006044:  stat_data.db startup time slow

- 0006038:  Access log broken data

- 0005943:  Dupliate Access-Log Entries when using host-level Redirect Rule with an IfMBeanEnabled condition
- 0006039:  session saving issue with forward

 

Upcoming fixes in the new 4.0.53 (in progress)

 

Resin – 4.0.53

==============

- 0005951: 4.0.46 bad install over existing 4.0.37

- 0005979: Double start of application

- 0006059: PHP is not reloaded after modification

- 0006061: TempCharStream null pointer

- 0006060: UnsupportedOperationException: com.caucho.bytecode.MethodTypeConstant

- 0006055: Add log-level configuration to resin.properties
- 0006058: NullPointerException @ buildInvocation(WebAppContainer.java:847) instead of 503 Service Temporarily Unavailable

 

Resin 4.0.52 improves efficiency of data and log storage. Resin 4.0.53 will also include single line configuration in resin.properties for enabling/disabling health and modifying logging content & levels of resin-data.

 

These changes are being implemented at the request of developers. Send us your bugs at http://bugs.caucho.com/main_page.php

Case Study – Korea's largest media company increases performance by 30% and reduces TCO by 40% by migrating from WebLogic to Resin

Check out these impressive performance and cost savings results for ChosunILBO, Korea’s largest media company that also publishes the most influential newspaper in the country. 
 

        “Before Caucho, we used WebLogic in our main business systems. By migrating to Resin, we 'caught two birds with one stone’ and successfully achieved high performance. We also reduced our total cost of ownership (TCO) by 40%.”

        - SeongHyun, Song, Sir. Development Team, ChosunILBO
 

Working with our Korean partners, Xest Information Technology, ChosunILBO replaced WebLogic with Resin. Engineers benefitted from the following changes in productivity, performance and scalability:

  • They could increase work efficiency​ ​rapidly​ ​by a simple setting method and configuration change 

  • They could apply​ ​app source changes without downtime even if application source code was altered frequently 

  • By using Resin’s lightweight and rapid restart in less than 10 seconds, they could minimize downtime and increase efficiency by over 30% 

Because Resin provides seamless integration with popular frameworks including Spring, iBatis and Struts, developers used Resin as the core for their vital applications while successfully integrating their legacy applications.
 
Read the full ChosunILBO case study here.

 

Caucho Partners with NTT Data Intramart Figtree Innovation Centre

  

In June 2017, Caucho joined the Intramart Figtree Innovation Centre in beautiful Sydney, Australia. The partnership was formalized in San Diego by Luis Ohri, Senior VP of NTT DATA Intramart; Ricky Au, CEO of NTT Data Figtree Systems and Steve Montal, CEO of Caucho.



This technology alliance will seek strengthen NTT DATA Intramart’s sales footprint in the Asia Pacific region, while bolstering NTT DATA Figtree Systems’ technology capability and service portfolio in business process management (BPM). The Intramart Figtree Innovation Centre recognizes the significant technical benefits and synergy of incorporating Caucho products, where customers can leverage the powerful architecture of Resin, Quercus and Baratine.

 

The Intramart Figtree Innovation Centre will seek to develop upon the existing product IP offered by NTT DATA Figtree Systems, NTT DATA Intramart and Caucho to provide a mutually beneficial sales model and growth strategy throughout the over 5,500 existing clients, distribution channels and NTT DATA Group companies.

 

Caucho is honored to join the Intramart Figtree Innovation Centre. We look forward to working with our friends in Australia!
 

 

Cool Resin Tip: Dispatch Rules

 

Controlling flow, access, and authorization within individual web-apps is simple with Resin.

Resin's dispatching is based on a list of dispatch rules configured in the resin-web.xml or the resin.xml configuration files. Each rule has a regular expression matching request URLs. The first dispatch rule that matches takes control of the request. For example, a <resin:Redirect> sends a HTTP redirect, and a <resin:Dispatch> dispatches the request as normal.

Each matching rule can rewrite the URL using a target attribute that accepts Java regular expressions. The following rule flips the first two segments around, so /foo/bar would become /bar/foo.

Basic conditions check the request and return true if the condition matches. Conditions can check on authentication (<resin:IfUserInRole>), the remote IP (<resin:IfNetwork>), check for SSL (<resin:IfSecure>), and check for activation time (<resin:IfCron>) or if a file exists (<resin:IfFileExists>).

The rewrite conditions can also be used as security conditions, e.g. for <resin:Allow> or <resin:Deny>.An action tag can have zero condition tags or at most one. If you want combine multiple conditions, then you'll need to use composite conditions like <resin:And>, <resin:Or>, <resin:Not>, <resin:NotAnd>, and <resin:NotOr>.

Example: send 403 Forbidden if port is 80 and user is not admin

<web-app xmlns="http://caucho.com/ns/resin"
​xmlns:resin="urn:java:com.caucho.resin">

<resin:Forbiddenregexp="^/secret">
<resin:And>
<resin:IfLocalPort value="80"/>
<resin:Not>
<resin:IfUserInRole role="admin"/>
</resin:Not>
</resin:And>
</resin:Forbidden>  

</web-app>

  
Download Resin and Develop up! 

 http://caucho.com/products/resin/download                                                   Facebook: Caucho Technology  Resin Twitter page

paradise-beach.jpg

 


Caucho Newsletter March 2017

paradise-sky.jpg  
          main caucho logo 3      
    Caucho at Devoxx - for the developers!

     Q1 has been filled with activity at Caucho!

Developer Sean Wiley is on the road presenting at key events including Devoxx US. We continue to collect valuable feedback from Resin users and look forward to the next release, Resin 4.0.51. We encourage you to report any issues with reproducible behavior to bugs.caucho.com website, or by reaching out directly to us at presales@caucho.com.

Newsletter at a Glance:Sun_with_Sunglasses_Transparent_Picture.png

  • Caucho presents Baratine @ Devoxx 2017, March 21-23 in San Jose
  • Caucho presents webinar with Elastic Beam
  • Caucho presents @ San Diego JUG
  • Resin High Availability Settings (Part 2)
 
Caucho Presenting Baratine @ Devoxx 2017
 

Join Caucho Engineer Sean Wiley for a “Tools in Action” presentation on server side Java. Sean will be presenting on operational service views using Caucho’s MicroService Platform Baratine (link to www.baratine.io)

Sean’s presentation will provide details into how MicroServices can improve high volume web services, making bottlenecks a thing of the past. The talk will integrate these services with current architecture, allowing developers to use platforms they are familiar with for next generation applications.

 

If you’d like to meet up with Sean for a coffee or beer during Devoxx, contact him at wiley@caucho.com

 

Devoxx conferences in Europe are famous for being vendor neutral community events, organized by developers, for developers. The events are always highly intellectual, geeky and fulfilling conversations with some of the best speakers and attendees in the industry.

Register for the event and find out more information here: http://cfp.devoxx.us/2017/index.html

Caucho/Elastic Beam Webinar
 

Ouch!!! We saw that Gartner estimates that downtime costs are >$300,000/hr with variation based on industry vertical and other factors. So we partnered with Elastic Beam to build a robust web application server environment that delivers performance, security and minimizes costly downtime.

 

Our webinar focused on simplifying and securing application infrastructures with example deployments. We also touched on the following questions: 

 

   What is causing availability issues with today’s Java EE application servers?

   What are the critical requirements to consider when building robust web-scale infrastructure?

   How do you build highly available web infrastructure with a software only approach to avoid significant costs?

   What types of hacker attacks do you need to worry about?

   How to secure your applications against malicious activity? 

   How to track API usage and detect abnormal behavior?

 

To  learn more, please reach out to us at presales@caucho.com.



San Diego JUG

We gave a talk at the San Diego Java Users Group on high availability of the Resin Application Server. The talk was well received and we were glad to share with the San Diego developer community details to improve their application deployments.
 

Check out the abstract: Uptimes, scalability, clustering and performance monitoring are all important aspects of running a successful Java Web Application. This talk will focus on real world examples of features and advanced configurations deployed in the Resin Application Server to achieve success in the aforementioned aspects. Features and examples covered will reveal how users of the Resin Application Server are achieving 99.99% uptime with their enterprise deployments.

Details and presentation slides are online at http://www.sdjug.org/meetings.

 

High Availability Part II - How does the Web Tier find the App Tier
 

Following up on Part I presented in January's newsletter, here is Part II. As always, we value your feedback so take a look and feel free to send your comments to wiley@caucho.com.  

​The Web Tier hosts the load balancer, which is configured in resin.xml with the following:
 

 

New Picture (1)

Note that resin:LoadBalance has a cluster parameter which will be used to find servers that serve that cluster (Tier). In the case above the cluster is called 'app'.
 

New Picture (2)

Web Tier resolves servers in the App Tier using resin.properties. Resin.properties configuration file must have a correct app_serversproperty which lists static App Tier servers. Once the Web Tier can find core servers of the App Tier it can resolve the dynamic servers using the cluster state that is communicated by the App Tier to Web Tier.

Deploying Web Applications

Web Applications should be deployed into App Tier using Resin deploy command. Once deployed into one of the three founding members of the cluster (the first three static servers defined in app_servers) application is replicated to the rest of the static and dynamic servers in the cluster. Deploying a foo.war application will look as so:

New Picture (3) 2

New Picture (4)

Configuring user name and password

Username and password are configured in resin.properties with admin_user and admin_password properties.

For production deployment the password must be generated with Resin's password command as so:

New Picture (5)

Lines admin_user and admin_password can be copied into resin.properties replacing the commented out admin_user and admin_password properties

 

For testing the password can be specified in plain text as so:
 

New Picture (6)

Cluster Security: Cluster Key

Cluster Key is used as a security token which allows participants in Resin Cluster Resin Servers to communicate. Cluster key should be specified in resin.properties as so:

New Picture (7) 

  
Extended – New Years gift to optimize your configuration! 

Contact Caucho engineer Sean Wiley at wiley@caucho.com or (858) 456-0300 to set up a complimentary review of your deployment, including learning about new Resin features and tips to optimize your configuration.

Download Resin                                                   Facebook: Caucho Technology  Resin Twitter page

paradise-beach.jpg

 





Caucho Newsletter January 2017

paradise-sky.jpg  
   
    
​  Celebrating 19 years as the #1 Java app server!

Sun_with_Sunglasses_Transparent_Picture.png"Though it rarely happens, whenever one of our domains goes down, Resin's watchdog monitor restarts it automatically. We have been using Resin for five years and have achieved 99.99% up time. It is very reliable and fast. We host several websites and we particularly like the ability to run each domain in its own isolated java virtual machine”

- Peter BetBasoo, Assyrian International News Agency

 

Resin 4.0.50 will be available for download this week on caucho.com/download. With many new fixes in the latest release, the number of open requests is down to 15! We recommend upgrading to the latest version for the highest performance and stability.

Notable bug fixes in 4.0.50:

  • 0006027:  ref #6009: Shutdown doesn't appear to give requests time to finish
  • 0006025: add ignore-lock
  • 0006023: NPE: tld discovery
  • 0006022: command jmx-list -operations NPE
  • 0005990: IndexOutOfRangeException in Caucho.IIS.LoadBalancer.OpenServer
  • 0005948: apr_pool_cleanup_register(config->web_pool, s, cse_cleanup_, NULL) at modules/c/src/common/stream.c:1848 cause segfault
  • 0006021: JSTL Custom tag upper to lowercase
  • 0006002: add custom global error page for 503 service unavailable
  • 0005918: resin crashes on server shutdown on windows with openssl
  • 0005916: OPENSSL: SIGSEGV
  • 0006017: db pool issues when full
  • 0006020: Resin.properties defaults with persistent sessions on
  • 0005969: forward in include with context /foo
  • 0006008: resin:Forward at host level does not forward if @regexp matching context exists
  • 0006015: Allow server id be muted on error pages
  • 0006014: proxy-cache not showing updated files
  • 0005957: Deployment of war file causes Java to use 100% CPU and Resin to crash
  • 0005989: Resin pauses for 30 or more seconds during startup performing some git operations

For bug fixes, email us at presales@caucho.com or submit bugs directly at http://bugs.caucho.com/main_page.php
 

Resin High Availability – easy default setup!
 

We want to make sure you are getting the best out of your Resin deployment. Through best practices gathered from emails, phone calls, and on-site visits, we continue to craft the default setup of Resin as a High Availability setup. To this end, we have put together a two-part overview that describes this setup.

 

The purpose of this overview is to familiarize new users with the architecture and configuration of Resin, and cement what long-time users may already know. As always, we value your feedback so take a look and feel free to send your comments to wiley@caucho.com.

Overview – Part I

Running a web application in high availability configuration requires a Resin Cluster. Resin cluster is a feature of Resin Pro which provides load distribution and session and cache replication.

 

In a minimal configuration with two application servers load can be split in two, with each server serving 50% of requests. In such a cluster consisting of two servers, sessions can be maintained in-memory or can be replicated between the two servers with each server has a copy of a every live session. This determination is dependent upon the session_store property in the resin.properties file which defaults to false.

 

A suggested Resin High Availability cluster with failover support should have three or more servers. Such configuration ensures that sessions and distributed cache data are triplicated providing extra redundancy for session data.

 

The core three servers of the cluster should be configured as static servers in resin.properties file. These three servers will construct the cluster core with each storing a full copy of all live sessions and distributed cache data.

 

Additionally a Load Balancer is required to balance load between cluster peers. Resin Pro provides Load Balancing capability as one of the core features of its Web Tier. If a hardware load balancer is used instead, it should be capable of supporting sticky sessions i.e. be capable of forwarding all requests from one client to the same Resin server. Sticky sessions help make the most efficient use of Resin cluster as each request is forwarded to the server where corresponding session was originated.

Configuration Files Overview

Default installation using:

1.  ./configure

2.  make

3.  sudo make install

will install Resin configuration files in the in /etc/resin directory

Resin Properties File

Named resin.properties the file configures values for Resin Pro standalone and Resin Pro cluster. Values from resin.properties are imported into resin.xml and cluster-default.xml

Resin Configuration File

Named resin.xml the file provides configuration for application and web (load balancer) clusters. File resin.xml imports values from resin.properties

Resin Default Configuration Files

Resin extracts default configuration into cluster-default.xml, app-default.xml files. Default configuration is imported into resin.xml and should rarely be changed.

Default Cluster Configuration

By default clusters for application and Web Tiers are defined in resin.xml. Application tier is used for hosting web applications while Web Tier is used for load balancing. Typically, requirements for Web Tier may not be as high as they are for App Tier which makes using fewer Web Tier servers with more servers in the App Tier possible.

Web Tier servers provide load balancing and web content caching, reducing load on the servers in App Tier.

Configuring App Tier Cluster in resin.properties:

Resin.xml exports server configuration for app and web clusters into resin.properties.

Servers for App and Web tiers are mapped to app_servers and web_servers properties respectively.

Excerpt below shows how to configure three servers in the App Tier cluster; let the App Tier ips range be between 192.168.1.10 and .19

Dynamic Servers

Both App Tier and Web Tier clusters support dynamic servers. Dynamic servers can be taken in and out of rotation on an as needed basis.

Enabling dynamic servers requires setting the following property in resin.properties
Jan_NL_PIC A

  

Starting Servers in the App Tier

Servers defined statically in resin.properties needs to start first. They will form the core of the cluster. Since the first three static servers compose the cluster core, cluster will operate normally as long as at least one of those servers is operational.

Starting the servers is achieved with bin/resinctl start –server app-33443 command.
Jan_NL_PIC B1
Jan_NL_PIC B2
​The 33443 parameter comes from the position of the server in app_servers (or web_servers )property.
 
For example server 192.168.1.10:6800 should be started with command:

Jan_NL_PIC C

Starting Dynamic servers in the App Tier

After static servers are started dynamic servers can join the cluster. Let the dynamic servers ip range start with 192.168.10.20 and start two dynamic servers:
Jan_NL_PIC D
Note, that the command requires specifying the ip and port to which to bind the new dynamic server. Note also, that specifying cluster name is required as well.

The cluster name maps to servers in the cluster using cluster servers property defined in resin.properties. All servers in the cluster should be using identical configuration i.e. they should all share the same resin.xml and resin.properties file, along with cluster-default.xml and app- default.xml if these files were changed.

Jan_NL_PIC E

Configuring Web Tier Cluster

Web Tier cluster exports its server configuration into web_servers property. Configuring the Web Tier servers is identical to configuring the App Tier's. Both tier clusters support adding dynamic servers.

Let the Web Tier have ips range start with 192.168.1.80:

 Jan_NL_PIC F 

Web Tier servers can be started independently of App Tier but the Web Application will start being served only after servers of the App Tier become operational.

Stay tuned for Part II in the next Caucho newsletter!

Resin Tip – Secure Virtual hosts Redirect
 
Did you know that you can issue secure redirects in Resin at the host level? This setup is advantageous for users who might use a load balancer listening on their secure port to redirect traffic to Resin. By having the response from Resin secure, you can avoid a “double redirect” for your traffic.
 
There are two ways to configure the host for the redirect.
 
1. Add a <host-name> to the <host>.
 
<host id="" host-name="https://www.foo.com">
     …
</host>
 
The redirect will use the host-name when filling in the redirect. That assumes you've got a single fixed virtual host, of course.
 
2. Add a secure="true" to the <web-app>.
 
<web-app secure="true">
     …
</web-app>
 
That secure="true" will tell Resin to assume the real connection is secure even though Resin itself isn't using an SSL connection. So redirects will use “https:” instead of “http:”.
 
 

New Years gift to optimize your configuration!
 
Contact Caucho engineer Sean Wiley at wiley@caucho.com or (858) 456-0300 to set up a complimentary review of your deployment, including learning about new Resin features and tips to optimize your configuration.

Download Resin                                                   Facebook: Caucho Technology  Resin Twitter page

paradise-beach.jpg

 





Newsletter September 2016

Resin application server - Java EE 6 Web Profile Certified

Baratine News

Introducing Baratine 1.0 – introducing the first fully reactive programming framework!

Baratine features include:

  • Websockets
  • Journaling
  • Automatice batching
  • Child services
  • Session services
  • Worker services
  • Templates and views
  • Publish/subscribe
  • Timers
  • Flow control support
  • Jackson JSON support
  • Zero dependencies
  • Kraken, an embedded, fully reactive database

Top 3 reasons to use Baratine!

  1. Reactive Programming - Asynchronous request processing can improve response times and lower resource consumption. Combining this with the ability to operate continuously on data solves many of the issues that plague multi-threaded and multi-tier programming.

  2. No database or concurrency bottlenecks – Most applications can operate with their data in-memory and persist state when needed. Baratine makes this possible as well as transparent to the developer as requests no longer need to touch a bottleneck database for every read & update.

  3. Agile development - One of the biggest hurdles for releasing into production is the unintended consequiences (i.e. resource consumption & dependencies) of a new service. However, if the service is a standalone .jar communicating with your app via REST or WebSocket, you can release new features to production with no potential impact to current application performance.

White Paper Preview

Abstract: Asynchronous and non-blocking execution is a highly coveted attribute of high volume web services. Server side web services strive to make contractual agreements upon interface based APIs to other services, assuming their environments to be highly-available, recoverable, & loosely-coupled. However these attributes are often in direct disagreement with an APIs implementation given: (1) the underlying multi-threaded libraries an API must rely upon and (2) the outside data source whose assets must be operated upon before an API can complete. This hindrance often results in contractual agreements across services tying down & blocking the multithreaded resources of a given architecture. This bottleneck is only half solved by frameworks where asynchronous request processing is paired with either NoSQL or SQL databases whose data access must block an incoming thread in order to make durable mutations on an asset. Techniques such as caching & sharding in-memory data structures alleviate the bottleneck for modifications on data at the cost of added complexity; exposing a view of the data that cannot be atomically mutated, results in complex and eventually consistent architectures.

In this paper we introduce Baratine… 
Continue reading the entire Baratine Technical White Paper here!

Check out the Baratine introduction page:
Baratine 5 min Overview Introduction

Why is Baratine a game changer?

Reactive processing meets reactive data.

Working with data is the critical path of every application. Baratine guarantees only a single service owning thread will mutate a service's data. This unique threading & data model does three things:

  1. Allows data to be operated on continuously
  2. Eliminates database bottlenecks
  3. Eliminates multi-threaded concurrency concerns

Baratine's internals guarantee every service to be highly available, recoverable, and operate within an isolated thread context.

Encapsulation boundary_Aug2016

Clean & understandable asynchronous REST services are the perfect fit for Baratine's model. Services are fast, as in millions of operations per second per instance fast, clients can be in any programming language, and applications operate entirely in-memory.

However, Baratine is much more than just a simple async REST framework. What has been described by SOA for years and recently rebranded as Microservices is for the first time achievable with Baratine in a 5 MB .jar. Baratine is designed for high performance, scalability, security, and stability – something that Java EE and Spring cannot deliver.

Baratine eliminates the hassles created by multithreaded environments including writing lines of complex concurrency code, debugging database bottlenecks and ensuring applications meet the best known industry standards.

Check out the following examples of how Baratine can immediately help your infrastructure:

Resin News

Resin 4.0 Tip – Max thread count

Every application is different in terms of threads used for answering requests. Resin ships with a default thread max count of 256, which is appropriate for many applications, but may be limiting how fast your application is running.
 
If you suspect this setting is impeding performance, first turn on finer logging. Then increase the max thread count in your Resin configuration file as follows:
 
<thread-max>2048</thread-max>
 
While this isn’t guaranteed to resolve every performance issue, having more workers answering requests in your application can significantly increase the overall performance. Who knows, you may find the actual bottleneck in your application (a database or cache perhaps? ;)  

Resin 4.0.49

The next release will be Resin version 4.0.49 and is scheduled for September. Contact us at sales@caucho.com if you’d like to receive an automated alert for this release. 

Helpful Information 


Arian Crockcoft's full presentation Microservices: State of the Union can be viewed at:

http://www.infoq.com/presentations/microservices-review
 
You'll notice he details a plethora of stacks one must combine in order to truly have a MicroService. We recommend using Baratine plus the likes of Docker, a build tool, and a security framework to get a leg up on the competition and outpace your rivals!

 


Copyright (c) 1998-2016 Caucho Technology, Inc. All rights reserved.
Caucho®, resin®, quercus® and baratineTM are registered trademarks of Caucho Technology, Inc.

 

 


Presentations & Links

 

Baratine

Baratine Overview

GitHub examples

Baratine Download

 

  Resin 4

Follow Us!

Facebook: Caucho Technology
Resin Twitter page
Caucho Blog

________________

Contact Us
(858) 456-0300
sales@caucho.com
  www.caucho.com 
  
    
 
 






Caucho Newsletter – December 2015

Resin application server - Java EE 6 Web Profile Certified

Happy Holidays! We have lots of updates for you. Here's a snapshot:
 
  • Resin 4.0.47 release
  • Baratine tutorials
  • Speak with a Caucho Engineer!
  • Resin tip of the day
Resin News

Resin 4.0.47 on caucho.com/download

The latest release of Resin v4.0.47 is now available for download. As with previous 4.0 releases, the upgrade process is as simple as stopping Resin, saving your configuration, installing the latest version, and copying over your config.

Many of our clients who have upgraded to this latest version report an increase in performance of their clustered applications.

Check out the following enhancements in 4.0.47:
 
JDK 6 compatibility

Distributed session database synchronization issues, specifically: 

  • session: fixes related to Java deserialization (#5947i)
  • distcache: locking overhead reduced (#5962)
  • distcache: update remove query and locking (#5952)
  • session: fixes related to session removal/timeout (#5952)
  • compile: jdk5 compile issues (#6940)
  • cache/mmap: jdk6 compatibility (#5959, #5960i)
The latest releases of Resin continue to improve performance and reliability as we work hard to fix any bugs that are reported. For this reason, we always recommend users update their Resin installation and take advantage of these improvements.
 

Baratine News


Baratine Patterns Tutorial

The latest version 1.0.3 is available at baratine.io/download. As more users implement and prototype services, we are seeing a common set of questions arise around functionality. Many of these questions relate to the use of Baratine, such as “What JSRs are supported by the Baratine Framework?”  This is actually a basic question in terms of functionality for Baratine. In short, Baratine does not support any of the JSRs specifically. Instead, Baratine supports the use of Java 8 and many programming patterns (http://doc.baratine.io/v0.8/patterns/) that can be used to build services. We believe that as it currently stands a large majority, upwards of 90%, of the web services developers are looking to build can be created with these patterns and the Baratine framework. 

What’s more, rather than coding to specific JSRs, Baratine allows you to code directly to Java 8. This means code is more standard, easier to read, and you’ll automatically enjoy the performance and scalability aspects of Baratine. While there is coding required that is specific to the Baratine framework, we have restricted it to Service level Annotations (http://doc.baratine.io/v0.8/manual/annotations/). These annotations allow developers to quickly and succinctly manage the lifecycle event of a service, similar to how annotations can be used to modify the lifecycle of a servlet.

If you know how to code in Java 8, then you are capable of building fully distributed web services with the ability to speak to any language and perform millions of operations per second per instance. Of course, this is made possible by the underlying Baratine framework which is complex in its coding, but exposes a POJO API that is naturally familiar to many developers.

Currently we are providing 10-15 minute tutorials (http://doc.baratine.io/v0.8/patterns/) that can be used to implement portions of an application or service. Here is the list: 

  • Hello World - How to deploy a Baratine Service and create a client to call into it
  • Single-Page Session - A session service used by a single-page application for user login state. Each user sessions creates a new session service instance
  • Singleton Resource Service - A service with a single resource, used to create new services from existing modules or from scratch
  • Queue with Application API - A user of a queue service submits a request and continues processing without waiting for a result
  • Local Microservice - Wrapping an existing module into a local microservice, similar to external creates encapsulated clean boundaries
  • Microservice - A microservice service is useful to convert an existing multi-threaded, blocking module into a loosely coupled service
  • Protocol for a Module - gives an existing module a HTTP protocol interface that supports HTTP request-response & WebSocket async protocol
  • In-Memory with External Database - An in-memory service layer that encapsulates a database better than a traditional passive cache
  • In-Memory Service with Internal Database - An in-memory service layer that persists data internally rather than an external database
  • Child Services - Build a REST-like Service with multiple child instances, each instance responsible for its own data
  • Setting up a Cluster - how to build a sharded service and deploy it to a cluster
  • Publish/Subscribe Stream - how to build a publish/subscribe service for Java and JavaScript clients
  • Publish/Subscribe Events - how to use publish/subscribe events in your services
  • Data Access Service - how to use Hibernate with Baratine
  • Singleton List Service - A single instance list service that maintains its own data
  • Multiple List Service - A multiple instance list service each independently maintaining their own data
  • REST Service - How to create a REST interface for a service
  • Facade Service - A facade service that allows you to expose an external API to a service, separate than the internal API

Are we missing a pattern? Let us know and we will implement it! :)

Helpful Information 


 

Have Questions Around Setting Up Clustering / HA?

Our Sales and Engineering teams are available to schedule calls with you to discuss Resin and Baratine as they apply to your specific environment. This benefit is included with your license and is a great way to learn about underlying models, features, performance and best practices that could be valuable to your development efforts and deployments.

Send an email to sales@caucho.com to schedule a call or contact us directly at 858-456-0300! Alternatively, if you are planning on being in the San Diego area, drop us a line and come by our offices to meet us in person!

Resin Tip

One of the most useful tools Resin provides for debugging is its logger. Resin has the ability to log any instance of a class and provide a detailed report of method invocation leading into and out of a class. Because of this, the log is usually the first place to look when something has gone awry with an application. By adding a simple one line logger to your resin.xml, you can enable the level of detail our engineers use to sort through various bugs. The following example details how quickly this can be done:

  1. Choose the name of the class or package you wish to log​.
    • Resin will log every class under a package name, i.e. com.foo logs com.foo.bar
  2. Choose the level of detail you wish to have logged.
  3. Add the logger to your resin.xml and restart your application
  4. Resin will output log files to /var/log/jvm-*app-server*.log

Example:
 (in resin.xml)
 
//Log HTTP-related debugging
<logger name="com.caucho.http”.server level=“finer”/>
 
//Log every class that matches com.foo.bar
<logger name="com.foo.bar” level=“finer”/>
 
Alternatively, you can provide logging in a specific class as follows:
 
import java.util.logging.Logger;
import java.util.logging.Level;
 
public class Foo {
  private static final Logger log
    = Logger.getLogger(Foo.class.getName());
 
  …
  void doFoo(String bar)
  {
    // check for log level if your logging call does anything more
    // than pass parameters
    if (log.isLoggable(Level.FINER))
        log.finer(this + "doFoo(" + bar + ")");
 
    …
 
    log.info(…);
 
    try {
        …
    } catch (ExpectedException ex) {
      log.log(Level.FINEST, "expected exception", ex);
    }
  }
  …
}

 


Copyright (c) 1998-2015 Caucho Technology, Inc. All rights reserved.
Caucho®, resin®, quercus® and baratine
TM are registered trademarks of Caucho Technology, Inc.


 Presentations   & Links
 

  Resin 4

Baratine

Baratine Overview

Follow Us!

Facebook: Caucho Technology
Resin Twitter page
Caucho Blog

__________________

Contact Us
(858) 456-0300
sales@caucho.com
www.caucho.com