<!--first: the template-->
        <bean id="DSJNDITemplate" class="org.springframework.jndi.JndiTemplate">
            <property name="environment">
                <props>
                    <prop key="java.naming.provider.url">
                        t3://localhost:7001
                    </prop>
                    <prop key="java.naming.factory.initial">
                        weblogic.jndi.WLInitialContextFactory
                    </prop>
                </props>
            </property>
        </bean>

<!--and: the dataSource-->
        <bean id="dataSourceJNDI" class="org.springframework.jndi.JndiObjectFactoryBean">
                <description>Main dataSource for app</description>
          <property name="jndiName">
                <value>services/MySQL_DS</value>
          </property>
          <property name="resourceRef">
              <value>false</value>
          </property>
          <property name="jndiTemplate">
              <ref local="DSJNDITemplate" />             
          </property>
        </bean>