Wednesday, February 23, 2011

The Spring Container Lifecycle


The Spring Container Lifecycle

When you mount an application context, Spring starts up, following a predictable lifecycle. The actions it performs are:
  1. Load all bean definitions before constructing beans
  2. Construct each bean via reflection
  3. Inject components via setters, autowired methods, etc...
  4. Post-process the bean
  5. Make the bean available for use by injection or direct lookup
Obviously we're going to focus on that post-processing step. It turns out Post Processing allows Spring's magic to happen.


http://java.dzone.com/articles/spring-corner-what-are-those?utm_source=feedburner&utm_medium=feed&utm_campaign=Feed%3A+javalobby%2Ffrontpage+%28Javalobby+%2F+Java+Zone%29