This forum is now a read-only archive. All commenting, posting, registration services have been turned off. Those needing community support and/or wanting to ask questions should refer to the Tag/Forum map, and to http://spring.io/questions for a curated list of stackoverflow tags that Pivotal engineers, and the community, monitor.
No announcement yet.
i need application context from my beanPage Title Module
I guess you are using ApplicationContextListener to load applicationContext-jdbc.xml and DispatchServlet to load billing-servlet.xml, right?
Spring, actually, will create two ApplicationContexts, a root ApplicationContext loaded by the listener and a child one loaded by the DisplacthServlet. Beans in the root AC are visible to beans in the child AC. the inverse is not correct. If my original assumption is true, you can access "that" bean from the controller because it is defined in the xml/utility.xml file (included in billing-servlet.xml).
To solve this issue you may remove the <import resource ...> from billing-servlet.xml and put it in applicationContext-jdbc.xml (this depends on what beans are declared in that file)
Hope this helps