camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Claus Ibsen <claus.ib...@gmail.com>
Subject Re: Missing datasource exception while referring to OSGI datasource for clustering quartz with camel-quartz
Date Tue, 03 Sep 2013 10:34:59 GMT
Hi

As its Quartz which does the DataSource lookup then wonder how it does
the lookup?
Though I assume spring users with quartz may have defined their data
sources as spring <bean>.
So maybe you can find some information how to tell quartz to lookup in
spring etc. Then spring-dm in OSGi ought to work with it.

There is also a new camel-quartz2 component in Camel 2.12. Maybe
quartz2 would work better with OSGi ?

On Sun, Sep 1, 2013 at 1:03 PM, lakshmi.prashant
<lakshmi.kala.venkatesan@sap.com> wrote:
> Hi,
>
>  I have already referred to the datasource (OSGI service) in the beans.xml:
>
>  <reference id="dataSource" interface="javax.sql.DataSource"
> filter="(dataSourceName=default)" />
>
> a) And I had already tried referring to the datasource using the reference
> id, in quartz properties:
>
>   <bean id="quartz"
> class="org.apache.camel.component.quartz.QuartzComponent">
>         <property name="properties"><props>
>                      <prop
> key="org.quartz.jobStore.dataSource">*dataSource*</prop>....
>           </props></properties>
>  </bean>
>
> b) Also, I had earlier tried to refer the datasource by the osgi service
> name..
>
>    <bean id="quartz"
> class="org.apache.camel.component.quartz.QuartzComponent">
>         <property name="properties"><props>
>                      <prop
> key="org.quartz.jobStore.dataSource">*default*</prop>....
>           </props></properties>
>  </bean>
>
>
> None of the 3 approached had worked.
>
> Exception trace while referring to bean reference id.
>
>
> Failed to obtain DB connection from data source 'dataSource':
> java.sql.SQLException: There is no DataSource named 'dataSource'
> org.quartz.JobPersistenceException: Failed to obtain DB connection from data
> source 'dataSource': java.sql.SQLException: There is no DataSource named
> 'dataSource' [See nested exception: java.sql.SQLException: There is no
> DataSource named 'dataSource']
>
> Thanks,
> Lakshmi
>
>
>
> --
> View this message in context: http://camel.465427.n5.nabble.com/Missing-datasource-exception-while-referring-to-OSGI-datasource-for-clustering-quartz-with-camel-quaz-tp5738400p5738423.html
> Sent from the Camel - Users mailing list archive at Nabble.com.



-- 
Claus Ibsen
-----------------
Red Hat, Inc.
Email: cibsen@redhat.com
Twitter: davsclaus
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen

Mime
View raw message