alanwilliamson

Grizzly 1.7 Released - Shows just what Java is made of

The Grizzly project has released its 1.7 version of its framework. Grizzly is a framework that lets developers really utilize the power of the NIO classes from Java. What does it all mean? In a nutshell - the ability to build high concurrent request based applications without dedicating a single thread to each connection.

In the old days, if you had 1000 clients connecting, you where pretty much forced to utilize a thread for every connection. This was costly, both in terms of memory, management and raw CPU power. The irony though, was that the majority of the threads were doing precious little, waiting mostly on I/O.

Java NIO allows you to remove this thread reliance and drop that once 1,000 threaded application down to only 10 or 20 threads. However, NIO isn't the easiest of things to get to grips with. It requires a different mindset and some struggle with this. Grizzly however, removes a lot of this and gives the developer the ability to concentrate on their application logic and not worry about the low-level plumbing.

I have been using Grizzly now for a while for an application that would have traditionally been a Servlet application. By removing all the overhead associated with the Servlet API, you can really make a Java application sing. The footprint of the application is very small, allowing for a very fast startup, and low CPU usage. Sadly, this is what the Servlet API was suppose to be from the start, but it morphed into yet another bloated, convoluted Java API. Grizzly takes back.

As an open source project from Sun, the documentation is surprisingly sparse, but the mailing list support is top notch, with fast and useful responses. Reminds me of the early days of the Servlet API now I come to think of it. The main lead, Jean-Francious Arcand does a great job managing this project.

Check it out.

Comments

Well I have been a part of a project team using Java and I remember facing lot of problems with even 100+ simultaneous connections to our web application.

In fact, we have to keep monitoring the apache logs to see if the connection count is increasing to divert traffic to another servers. Of course, it was like 3-4 years back but it just clicked in my mind that this could have been much better framework then.

Nevertheless, I have forwarded this blog post link and the grizzly official link to my colleague who is still working in Java.

left by Joseph — Saturday, 28 June 2008 11:44 AM — web site

Wow, it took Sun only about 12 years to expose this feature available on every modern OS. Windows 95 had overlapped IO. kqueue for BSD unix and OS X has been around a while. I can't imagine trying to write a high performance socket server without it.

left by Jeffrey Rennie — Friday, 28 December 2007 10:46 PM

Leave Comment

please note, all comments will be moderated for spam and abuse before being publicly posted.


 

Recent Cloud posts

Recent JAVA posts

Latest CFML posts


 
Site Links
Recommended Sites/Blogs

Follow javachampion on Twitter