Hello,

in my appuse 1.8 based application I want some to override bean defintions
in applicationContext-service.xml with a local context file, to achive the
following:

Note: In case of multiple config locations, later bean definitions will
override ones defined in earlier loaded files. This can be leveraged to
deliberately override certain bean definitions via an extra XML file.

But to do this I must be able to change the definition of
ClassPathXmlApplicationContext, I guess.
Where should I put this? I tried this:

        <!-- JNDI DataSource for J2EE environments -->
        <bean id="dataSource"
                class="org.springframework.jndi.JndiObjectFactoryBean">
                <property name="jndiName">
                        <value>java:comp/env/jdbc/flowexpense</value>
                </property>
        </bean>
        <bean id="aBeanId"
        
class="org.springframework.context.support.ClassPathXmlApplicationContext">
                <constructor-arg>
                        <list>
        
<value>classpath*:META-INF/applicationContext-hibernate.xml</value>
        
<value>classpath*:META-INF/applicationContext-service.xml</value>
        
<value>classpath*:META-INF/applicationContext-local.xml</value>
                        </list>
                </constructor-arg>
        </bean>

But dataSource isnt found then.

Thanks
René

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to