Free Trial

Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.


A beginner’s guide for Java developers

  • Design, develop, test, and deploy your web applications using Struts 2 framework

  • No prior knowledge of JavaScript and CSS is required

  • Apply the best of agile development techniques and TDD techniques

  • Step-by-step instructions and careful explanations with lots of code examples

In Detail

Struts 2.1 is a modern, extensible, agile web application framework suitable for both small- and large-scale web applications.

The book begins with a comprehensive look at Struts 2.1 basics, interspersed with detours into more advanced development topics. You'll learn about configuring Struts 2.1 actions, results, and interceptors via both XML and Java annotations. You'll get an introduction to most of the Struts 2.1 custom tags and learn how they can assist in rapid application prototyping and development.

From there you'll make your way into Struts 2.1's strong support for form validation and type conversion, which allows you to treat your form values as domain objects without cluttering your code. A look at Struts 2.1's interceptors is the final piece of the Struts 2.1 puzzle, allowing you to leverage the standard Struts 2 interceptors as well as implement your own custom behavior.

After covering Struts 2.1 you'll journey into the world of JavaScript, a surprisingly capable language, the Document Object Model (DOM), and CSS, and learn how to create clean and concise client-side behavior. You'll leverage that knowledge as you move on to Struts 2 themes and templates, which give you a powerful way to encapsulate site-wide user interface behavior.

The book closes with a look at some tools that make the application development life cycle easier to manage, particularly in a team environment, and more automatic.

Subscriber Reviews

Average Rating: 2.5 out of 5 rating Based on 2 Ratings

"Best Struts2 Book Out there" - by DevelopIntelligence on 13-SEP-2011
Reviewer Rating: 1 star rating2 star rating3 star rating4 star rating5 star rating
We deliver a lot of developer training over at DevelopIntelligence. And constantly reference books in our classes.

Within Safari there is a small handful of Struts books. And each has it's positives and negatives. But, if you're adopting Struts2 coming from a Struts1 world, this book is direct, to the point, and will get you on your way quickly.

Our biggest complaint is the interwoven mixture of XML v. annotation based examples. It would have been better if teach technique had its own treatment.

Report as Inappropriate

"Not for beginners" - by johnnieb on 03-MAY-2011
Reviewer Rating: 1 star rating2 star rating3 star rating4 star rating5 star rating
The first few chapters provide a good overview of the technology. However, as a someone familiar with early versions of Struts 1, I found myself getting lost in Chapter 2 - Basic Configuration. The author does not spend enough time on XML configuration and how it relates to the major elements of Struts 2, i.e., dispatchers, interceptors, actions, and results. The author assumes we don’t like XML. So, he decides to cover non-XML conventions and annotations. Ironically, the annotations seem to be more complex than the XML they replace.

I would have preferred a detailed treatment on XML configuration as a foundation of my understanding of Struts 2. I could have learned the other configuration options after I felt comfortable with XML. I don’t recommend this book for anyone trying to learn Struts 2.

Report as Inappropriate

Table of Contents