and in your common.xml file you can import as many config files are you want. and here you can specify a class path resources
eg. <import resource="classpath:spring/repos.xml" /> <import resource="classpath:spring/dbDatasource.xml" /> <import resource="classpath:spring/jaxwsspring.xml" /> <import resource="context-beans.${TARGET_ENV}.xml" /> <import resource="classpath:spring/mail.xml" /> <import resource="classpath:spring/services.xml" /> <import resource="classpath:spring/paypal.xml" /> <import resource="classpath:spring/trackTableEditor.xml" /> On Fri, Jun 20, 2008 at 2:24 PM, Youssef Mohammed < [EMAIL PROTECTED]> wrote: > you have to add this instead > /WEB-INF/classes/common.xml > > > > > On Fri, Jun 20, 2008 at 1:38 PM, DCVer <[EMAIL PROTECTED]> wrote: > >> >> Hi all, >> >> I have strange problem. I am building standard web application (with >> Maven). >> The structure of the output WAR is as follows: >> >> WAR >> | - - META-INF >> | | - - ... >> | >> | - - WEB-INF >> | - - classes >> | | - - compiled_classes >> | | - - all_necessary_files (e.g. common.xml) >> | >> | - - lib >> | | - - all_necessary_jars >> | >> | - - beans.xml >> | - - web.xml >> >> In web.xml I need to load few configuration files (for Spring - in this >> example it is common.xml file): >> >> <web-app> >> [...] >> <context-param> >> <param-name>contextConfigLocation</param-name> >> <param-value>common.xml</param-value> >> </context-param> >> [...] >> </web-app> >> >> While deploying the application in Tomcat I receive errors (from Spring I >> guess), because Spring or Tomcat doesn't see the common.xml file (which is >> located in WEB-INF/classes). Aren't files in WEB-INF/classes added to >> classpath? If i specify WEB-INF/classes/common.xml path, the file is seen >> by >> Spring, but I use also other Spring configuration files (can't be >> modified), >> which need to refer to these files without WEB-INF/classes path >> (param-value >> = common.xml). >> What is more we have some WAR files with the configuration shown above >> (like >> <param-value>common.xml</param-value>) and everything works fine. So why I >> receive the error? >> >> Hope that is not as hard to solve as it seems to me! >> -- >> View this message in context: >> http://www.nabble.com/Spring-or-Tomcat-forgets-the-classpath--tp18026497p18026497.html >> Sent from the Tomcat - User mailing list archive at Nabble.com. >> >> >> --------------------------------------------------------------------- >> To start a new topic, e-mail: users@tomcat.apache.org >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> For additional commands, e-mail: [EMAIL PROTECTED] >> >> > > > -- > Regards, Youssef -- Regards, Youssef