Project: talendesb
Issue TESB-3985: Make DB DataSource plugable in OSGi by importing it as an OSGi service and configurable via jndi in Tomcat
We currently define the datasource for sam in the spring config. This works but is not a good solution. I propose we reference the DataSource from jndi when in tomcat and as an OSGi service when in OSGi. It might even be possible to use jndi in OSGi with the new OSGi specs. We should also think about providing a generic mechanism for Karaf to configure DataSources as an administrator. See: http://www.osgi.org/download/r4v42/r4.enterprise.pdf Chapter 125 http://www.osgi.org/javadoc/r4v42/org/osgi/service/jdbc/DataSourceFactory.html
Story points: 5