Skip to main content

Professional Java Development with the Spring Framework

Professional Java Development with the Spring Framework

Rod Johnson, Jürgen Höller, Alef Arendsen, Thomas Risberg, Colin Sampaleanu

ISBN: 978-0-471-74894-6

Aug 2007

676 pages

Select type: E-Book

Product not available for purchase


The Spring Framework is a major open source application development framework that makes Java/J2EE(TM) development easier and more productive. This book shows you not only what Spring can do but why, explaining its functionality and motivation to help you use all parts of the framework to develop successful applications.

You will be guided through all the Spring features and see how they form a coherent whole. In turn, this will help you understand the rationale for Spring's approach, when to use Spring, and how to follow best practices. All this is illustrated with a complete sample application. When you finish the book, you will be well equipped to use Spring effectively in everything from simple Web applications to complex enterprise applications.

What you will learn from this book
* The core Inversion of Control container and the concept of Dependency Injection
* Spring's Aspect Oriented Programming (AOP) framework and why AOP is important in J2EE development
* How to use Spring's programmatic and declarative transaction management services effectively
* Ways to access data using Spring's JDBC functionality, iBATIS SQL Maps, Hibernate, and other O/R mapping frameworks
* Spring services for accessing and implementing EJBs
* Spring's remoting framework

Who this book is for

This book is for Java/J2EE architects and developers who want to gain a deeper knowledge of the Spring Framework and use it effectively.

Wrox Professional guides are planned and written by working programmers to meet the real-world needs of programmers, developers, and IT professionals. Focused and relevant, they address the issues technology professionals face every day. They provide examples, practical solutions, and expert education in new technologies, all designed to help programmers do a better job.


Chapter 1: Introducing the Spring Framework.

Chapter 2: The Bean Factory and Application Context.

Chapter 3: Advanced Container Concepts.

Chapter 4: Spring and AOP.

Chapter 5: DAO Support and JDBC Framework.

Chapter 6: Transaction and Resource Management.

Chapter 7: Object/Relational Mapping.

Chapter 8: Lightweight Remoting.

Chapter 9: Supporting Services.

Chapter 10: Acegi Security System for Spring.

Chapter 11: Spring and EJB.

Chapter 12: Web MVC Framework.

Chapter 13: Web View Technologies.

Chapter 14: Integrating with Other Web Frameworks.

Chapter 15: The Sample Application.

Chapter 16: Conclusion.

Appendix A: Requirements for the Sample Application.


Code Downloads
Code downloads for this title are available here.
Source Code Download #2
This file contains an application which includes source for part of chapter 14.
CH10 acegi-security 0.7 snapshot
ChapterPageDetailsDatePrint Run
Code Replacement,The content for this title has been posted and may be accessed via:,descCd-download_code.html
40Error in Text,The sample source code assumes existence of class/interface: WeatherData that is not defined. An experience user, could assume it is a bussiness object corresponding to the weather data, but there is no mention to that. I am not sure at this moment, but in the book there is a mention to WeatherService, when they want to talk about WeatherData. 10/19/05
51Error in Code,The second last code snippet:

ApplicationContext appContext = new ClassPathXmlApplicationContext(
new String[] { applicationContext
serviceLayer.xml , applicationContext-
dao.xml });

should be read as:

ApplicationContext appContext = new ClassPathXmlApplicationContext(
new String[] { applicationContext-
services.xml , applicationContext-
dao.xml });
55Error in Text, noStaticFactory the quote is in bold face, the same for getTestBeanInstance 10/19/05
68Error in Code,public void setWeatherDao(DataSource dataSource) ...

should be:

public void setDataSource(DataSource dataSource) ...
78Error in Code,3rd code example
should be
87Error in Text,Last paragraph getMessage() variant()

should be

187Error in Text,1st paragraph after the text box, some part of the text is in courier and should be in normal font.10/19/05
9360Error in Text (Missing Source Code),The comment on page 360 is erroneous:
There is no additional source code for chapter 9.

The only source code is that which is printed in the chapter.
424Error in Code,the first import statement:

import org.springframework.web.servlet.mvc.ModelAndView;

should be:

import org.springframework.web.servlet.ModelAndView;
444Error in Text,first paragraph, last line:

the reference to Chapter 9 should actually be to Chapter 6.
445Error in Text,second paragraph, last line:

the reference to Chapter 9 should actually be to Chapter 14.
445Error in Text,second to last paragraph, last line:

the reference to Chapter 9 should actually be to Chapter 6
453Error in Code,In the XML snippet for bean definition the code reads:
<bean id= viewResolverTwo
class= org.springframework.web.servlet.view.InternalResourceViewResolver >
but neither org.springframework.web.servlet.view.InternalResourceViewResolver or it's superclassess implements interface Orderable, thus there is no setOrder method available.

This example does indeed contain an error with respect to Spring 1.2: The order property line needs to be dropped. Everything should work as expected then.

Spring's InternalResourceViewResolver does implement the Ordered interface as of Spring 2.0, in conjunction with UrlBasedViewResolver's new viewNames property.