I was just thinking that when should I actually consider loading more than one application contexts in Spring? All so far I have been merging the context files with <include> such that only one application context loads up.
Do you have an idea about when to go for more than one application contexts in the same JVM?
When you need to use hierarchical contexts, for example - like Spring MVC does. Your "web" context is loaded separately from your "main" context, so stuff defined in "main" context (services / DAOs / etc) is available to "web" but not the other way around.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With