Unleash the Java Web Server and the Servlet API

Covers more than just the Java Web Server, the Servlet coverage is invaluable, practical examples, well presented.


ORIGINAL DRAFT

The release of the Java Web Server provided Sun with both a great product and a clear demonstration of Java’s viability for developing large-scale applications, showing how uniquely suited it was to server-side development. Sun used the Java Web Server to implement a reference version of the Servlet API which introduced servlet beans, Java Server Pages (JSP), the <SERVLET> tag and a host of other innovations which are now part of virtually every third party implementation of the Servlet API. As such, this book provides a great guide to sophisticated web developers, covering session handling, templates and a number of advanced topics.

This book does not try to be an introduction to the Java Web Server. Instead, it is designed to provide a deeper understanding of the JWS as a platform for developing sophisticated web applications. Some of the information in these pages are invaluable to companies who’ve made a commitment to the JWS somewhere in their web offering. The first few chapters cover the JWS components, installation, using alternate Java Virtual Machines and basic administration issues. Up to this point, the focus is entirely on the JWS, but subsequent chapters delve into the Servlet API and techniques you’ll find useful across a number of Servlet engines in production today.

Chapters 5 and 6 introduce the GenericServlet class, the root of all the servlet classes, and cover more advanced concepts, including servlet-chaining issues. Chapter 7 talks about the HTTP protocol. Most web application rely heavily on HTTP, as do most servlets. HTTP servlets are covered in more detail in Chapter 8 and expanded on in Chapter 9. This books does a pretty respectable job of comparing performance characteristics of servlets in real-world circumstances. The author’s first comparison of CGI and the Servlet API shows that the Servlets are at least twice as fast as a CGI program. He goes on to optimize the example and shows that performance can be as high as 15 times faster. This coverage alone is probably worth the price of the book.

Other optimizations include using caching to your advantage. Chapter 10 pays special attention to related issues. Session management, which makes a stateless protocol (HTTP) capable of handling application complexity with amazing ease, is easy to use but full of implications. Chapter 11 shows a sample application that accesses a Directory Server through the LDAP protocol. This is a nice look a the JNDI (Java Naming and Directory Interface) providing insights into LDAP and directory server usage. Chapter 12 covers servlet beans and Chapter 13 looks at the Java Server Pages API. This is one of the most powerful applications of server-side component architectures and another invaluable part of the book.

If you work directly with the Java Web Server or plan to, this book is for you. It is not an administrative book but rather targeted at developers. Despite the JWS focus, the Servlet coverage is as good as, and in many cases better, than the servlet books available at this time. If you work with the Servlet API, you’ll inevitable learn something new between these pages. If you plan to work with JSP or server Java Beans, buy it, and if you need some evidence that Java is a great investment on the server side, check it out. All in all, I found this book well written and full of useful information. It’s pragmatic and comprehensive, and a good choice for any servlet programmer.