hello everyone,
i am new to struts2.
i use struts2, spring2.5 and hibernate 3.3.1 to build a simple website.
and have some questions about the order of the objects instantiate.
here is my config file for spring:
-applicationContext.xml
...
...
-applicationContext.xml
and when i start the tomcat, before running my project,
i get the logs like this:
---log
contents
Loaded 6 bean definitions from location pattern
[/WEB-INF/applicationContext.xml]
..
6 beans defined in
org.springframework.web.context.support.xmlwebapplicationcont...@179dce4:
display name [Root WebApplicationContext]; startup date [Thu May 14
08:44:00 CST 2009]; root of context hierarchy
..
Pre-instantiating singletons in
org.springframework.beans.factory.support.defaultlistablebeanfact...@6210fb:
defining beans
[Login,personService,PersonDAO,sessionFactory,dataSource,ChartAction];
root of factory hierarchy
Creating shared instance of singleton bean 'personService'
Creating instance of bean 'personService'
Eagerly caching bean 'personService' to allow for resolving potential
circular references
Creating shared instance of singleton bean 'PersonDAO'
Creating instance of bean 'PersonDAO'
Eagerly caching bean 'PersonDAO' to allow for resolving potential
circular references
Creating shared instance of singleton bean 'sessionFactory'
Creating instance of bean 'sessionFactory'
Eagerly caching bean 'sessionFactory' to allow for resolving potential
circular references
Creating shared instance of singleton bean 'dataSource'
Creating instance of bean 'dataSource'
Eagerly caching bean 'dataSource' to allow for resolving potential
circular references
---log
contents
does that mean
1) before running my project, spring has already instantiate all the
object defined in the applicationContext.xml?
such as LoginAction,PersonServiceImpl and sessionFactory?
2) the action used in struts2 is instantiated before a request comes
in? or is instantiated when a real request comes in?
3) with spring,what is the role of struts2 ? it seems that the
responsibility of instantiate object is changed to spring, not
struts2.
thanks.
-
To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
For additional commands, e-mail: user-h...@struts.apache.org