I am trying to understand a web system using spring and I can not debug it. Now I am confused by the order of the XML initialization.
Support I have an web.xml which is like this:
<context-param>
<param-name>contextConfigLocation</param-name>
<param-value>
classpath*:/com/pathA/**/applicationContext*.xml,classpath*:/com/pathB/**/applicationContext*.xml
</param-value>
</context-param>
and in /com/pathA I have some xml files that define some beans with the same name. In /com/pathB I also have some xml files that define beans with the same name as in com/pathA's xml file.
I know that spring framework will use the last bean definition by default.But I can't find the order of the xml files initialization.
Here is the beans' definition:
/com/pathA/applicationContextOne.xml
<bean name="/testBean" class="com.TestActionOne">
</bean>
/com/pathA/applicationContextTwo.xml
<bean name="/testBean" class="com.TestActionTwo">
</bean>
/com/pathB/applicationContextThree.xml
<bean name="/testBean" class="com.TestActionThree">
</bean>
can anyone can tell me the initialization order of the differnet xml files in /com/pathA/
and the initialization order of the xml files between com/pathA/ and com/pathB?