Hi Sebastien,

Friday, April 22, 2005, 3:40:05 AM, you wrote:

SA> I'm having trouble with beanRefFactory.xml generated by spring
SA> cartridge. I don't understand why it defines the datasource in one
SA> file (applicationContext-datasource.xml), all the other beans in the
SA> other file (applicationContext.xml), instead of generating all bean
SA> definitions in one single applicationContext.xml file.
SA> I don't understand it and it causes me troubles (and headaches :o) to
SA> access my beans. Is it possible to modify that behaviour and generate
SA> all bean definitions, including the datasource into a single
SA> applicationContext.xml file ? How ?

the reason why we generate a separate file for the datasource is that
we want to be able to test the generated Spring beans outside the
application server.

We want to use different datasources for production and for
integration tests. In the case of integration tests, we use another
file for the datasource because we test outside the application
server, using a simple DriverManagerDataSource instead of a
JndiObjectFactoryBean.

You should simply find all your beans through the ServiceLocator class
which is generated by the Spring cartridge, without any headaches at
all! Which kind of problems did you have?

Cheers...
Matthias

---

Matthias Bohlen
"Consulting that helps project teams to succeed..."

Internet:
   http://www.mbohlen.de/
   [EMAIL PROTECTED]




-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
_______________________________________________
Andromda-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/andromda-user

Reply via email to