While most other books merely instruct on basic JSP and servlet development, JSP Examples and Best Practices gives you some of the best practices and design principles, enabling you to build scalable and extensible enterprise Java applications. And JavaServer Pages technology can be used to build complex enterprise applications in a highly re-usable manner.
This book takes basic JSP and applies sound architectural principles and design patterns, to give you the tools to build scalable enterprise applications using JSP. Further, this book covers new features of the JSP 1.2 specification, including the standard filtering mechanism.
User review
Good Intermediate JSP Book
This book will probably be most useful to someone who knows JSPs and servlets and has worked with them, and is looking for better or alternative ways of writing JSP applications.
The first two chapters provide a review of JSPs and an overview of web deployment. They include a nice JSP/MySQL example, with
instructions indicating how to build the MySQL database and incorporate into the JSP example using JDBC.
Chapters 3 and 4 include discussions and examples of how to use JavaBeans and custom tags. The JavaBean example shows how to handle the display of a large amount of data retrieved from a database.
The use of J2EE patterns is discussed in the next several chapters, as befitting a book with `best practices` in its title. The four patterns covered are the Decorating Filter, Front Controller, View Helper, and Dispatcher View.
The remainder of the book covers some topics that are not directly connected to JSPs, but may be useful in a wide range of software applications. These include regression testing, and the use of JUnit and JMeter; deployment, and Ant and CVS, as well as precompiling JSP pages; and application frameworks, including an example.
In short, the book includes a collection of topics not often found in a JSP book.
I noticed some minor quibbles, such as use of single-character variables and older break tags (rather than
),
but generally speaking I find the book to be quite informative and practical, especially in the discussions and use of open source software such as MySQL, JUnit, JMeter, and Ant, with JSPs.
User review
The best book on JSP / Web application development
This book draws a clear picture on JSP web application development. If you are a JSP beginner, this book is a must read. It teaches you the right way to do things from the beginning.
I really enjoyed its step by step approach that leads to the framework based application development, makes a lot of sense to me.
User review
Disappointing read
I can save you money on the purchase of this book. If you can answer `yes` to the questions below, there is no need to buy this book:
* Do you know what JSP and servlets are?
* Do you know how to separate presentation and business logic with JavaBeans and custom tags?
* Are you familiar with MVC?
If so, no need for the book. I was expecting much more. It's less best practice, and more typical web app development. What disappointed me further was various comments in the text that displayed poor practices in areas outside of JSP web development, e.g. `the first step in developing a jsp web application is designing the user interface.`
My one-star rating can be summarized as follows:
* Poor typesetting and book formatting: -1
* Very few `best practices` -2
* Below average writing, low content-to-price tag ratio -1
User review
Fills an important niche
I am teaching myself server-side Java programming. After reading, using, and reviewing many books on Java server-side web development, I had found they fell into two categories: Beginner and advanced. The beginner books typically introduce a lot of bad coding practices, such as filling JSP pages with java code, or using outdated examples of Servlets that output HTML. After a few chapters of this, they jump to the Struts framework, thereby never helping the reader build good coding practices and skills.
The advanced books get quickly into frameworks like Struts, and also employ EJBs. EJBs are not needed in many web applications, where they introduce unneeded complexity. What I wanted but couldn't find was a good book that covered the middle ground: how to build applications based on JSPs and Servlets that demonstrate good design and coding practices, with a realistic sample application, and yet understandable for someone learning the J2EE technology.
When I found this book I was surprised to see that it concisely and clearly presented all the key topics I had hoped for. I found it by accident, because I never would have guessed from the scant 3 or 4 reviews on Amazon that it would be worth looking at.
Prerequisite knowledge for this book is basic Java skills and an introductory understanding of JSPs and Servlets. I liked this because so many beginner books spend a lot of time going over the basics. The book covers all the key intermediate-level topics you'll need to get started coding good Java web applications. This book goes beyond others I read in also showing how to use JUnit to do unit testing, and Ant to do application deployment. The author demonstrates these so clearly and simply that a person new to these tools will find it easy to follow and put to use.
Finally, the author finishes with taking the reader through how to build a basic but solid application framework that even the beginner to frameworks can follow. This framework is no Struts with its relatively steep learning curve. By the time the reader has got to the framework chapter he has learned what he needs to understand the framework. As if this were not enough, the author then shows how to deploy the framework, and then use it to build a sample application. All this is done in slim, concise, easily-to-follow chapters and code that is clearly and completely presented. You won't have to go hunting through the source code download or CD to research a bunch of code that is not illustrated in the book itself. It's all in the book.
A previous review rated this book low because he thought it didn't have a realistic application. I don't know what he is looking for exactly, but I thought the application was quite real enough in giving a fully functioning, realistic, web application. It is no super app, but neither is it a toy app. Again, it aims for the later novice to intermediate-level skill set. And I think it succeeds well.
User review
Not bad, but could be better
I agree mostly with what some of the other positive reviews read. The discussion about different design patterns was interesting to read.
However, I did get caught up on the source code in the book. I would think that a book is supposed to be about `best practices` would handle quotes in database inserts/updates. Is it common practice to assume that your form data will never contain erroneous information that will cause your system to fail?
I don't want to harp on this book too bad (many others are worse), but I am still searching for a solid JSP book that has sample code on how to build a solid/useful application from start to finish, while maintaining a clean separation of business logic and actual presentation.