Re: [Dev] C5- Datasource startup order issue

2016-03-19 Thread Himasha Guruge
Thanks for the explanation Kishanthan.It seems that the JNDI and data
sources bundles used were outdated.  Was able to solve the issue with a
reference to JNDIContextManager.

On Tue, Mar 15, 2016 at 5:44 PM, Kishanthan Thangarajah  wrote:

>
> On Tue, Mar 15, 2016 at 11:28 AM, Himasha Guruge 
> wrote:
>
>> Hi Sameera,
>>
>> Thanks for the provided info.In bpmn component   to  build  activiti
>> engine, we require the datasource bundle to be available. Therefore we
>> tried adding  @Reference annotation  of
>> org.wso2.carbon.kernel.datasource.core.internal.DataSourceListenerComponent
>> (for activate method of ActivitiEngineBuilder) but this did not work.
>>
>
> Why this did not work? What's the issue?
>
>>
>>  AFAIU what you suggest is to implement a Listener class that would
>> contain onJNDIReady() method, which would require other bundles(activiti
>> bundle in this case) to wait until this method is executed.  Could you
>> please provide any suggestions on this?
>>
>
> To use JNDI in carbon OSGi env, you have to add a mandatory reference to
> JNDIContextManager and then wait on until it's available. This will be our
> recommendation. Can you explain the use case of activity bundle and
> datasources and the ordering issue you are facing with the above approach?
>
>
>
>> Regards,
>>
>>
>> On Tue, Mar 15, 2016 at 8:52 AM, Sameera Jayasoma 
>> wrote:
>>
>>> HI Himasha,
>>>
>>> You can refer following documents and samples.
>>>
>>> https://github.com/wso2/carbon-jndi
>>>
>>> https://github.com/wso2/carbon-datasources/blob/master/sample/src/main/java/org/wso2/carbon/datasource/sample/DataSourceServiceListenerComponent.java
>>>
>>> On Tue, Mar 15, 2016 at 4:08 AM, Himasha Guruge 
>>> wrote:
>>>
 Hi Sameera,

 With regards to $subject, so far we have used the workaround of
 manually renaming the bundle's symbolic name which works perfectly. However
 is it possible to know when this fix will be available?

 Regards,

 Himasha Guruge
 *Software Engineer*
 WS*O2* *Inc.*
 Mobile: +94 777459299
 himas...@wso2.com

>>>
>>>
>>>
>>> --
>>> Sameera Jayasoma,
>>> Software Architect,
>>>
>>> WSO2, Inc. (http://wso2.com)
>>> email: same...@wso2.com
>>> blog: http://blog.sameera.org
>>> twitter: https://twitter.com/sameerajayasoma
>>> flickr: http://www.flickr.com/photos/sameera-jayasoma/collections
>>> Mobile: 0094776364456
>>>
>>> Lean . Enterprise . Middleware
>>>
>>>
>>
>>
>> --
>> Himasha Guruge
>> *Software Engineer*
>> WS*O2* *Inc.*
>> Mobile: +94 777459299
>> himas...@wso2.com
>>
>> ___
>> Dev mailing list
>> Dev@wso2.org
>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>
>>
>
>
> --
> *Kishanthan Thangarajah*
> Associate Technical Lead,
> Platform Technologies Team,
> WSO2, Inc.
> lean.enterprise.middleware
>
> Mobile - +94773426635
> Blog - *http://kishanthan.wordpress.com *
> Twitter - *http://twitter.com/kishanthan *
>



-- 
Himasha Guruge
*Software Engineer*
WS*O2* *Inc.*
Mobile: +94 777459299
himas...@wso2.com
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] C5- Datasource startup order issue

2016-03-15 Thread Kishanthan Thangarajah
On Tue, Mar 15, 2016 at 11:28 AM, Himasha Guruge  wrote:

> Hi Sameera,
>
> Thanks for the provided info.In bpmn component   to  build  activiti
> engine, we require the datasource bundle to be available. Therefore we
> tried adding  @Reference annotation  of
> org.wso2.carbon.kernel.datasource.core.internal.DataSourceListenerComponent
> (for activate method of ActivitiEngineBuilder) but this did not work.
>

Why this did not work? What's the issue?

>
>  AFAIU what you suggest is to implement a Listener class that would
> contain onJNDIReady() method, which would require other bundles(activiti
> bundle in this case) to wait until this method is executed.  Could you
> please provide any suggestions on this?
>

To use JNDI in carbon OSGi env, you have to add a mandatory reference to
JNDIContextManager and then wait on until it's available. This will be our
recommendation. Can you explain the use case of activity bundle and
datasources and the ordering issue you are facing with the above approach?



> Regards,
>
>
> On Tue, Mar 15, 2016 at 8:52 AM, Sameera Jayasoma 
> wrote:
>
>> HI Himasha,
>>
>> You can refer following documents and samples.
>>
>> https://github.com/wso2/carbon-jndi
>>
>> https://github.com/wso2/carbon-datasources/blob/master/sample/src/main/java/org/wso2/carbon/datasource/sample/DataSourceServiceListenerComponent.java
>>
>> On Tue, Mar 15, 2016 at 4:08 AM, Himasha Guruge 
>> wrote:
>>
>>> Hi Sameera,
>>>
>>> With regards to $subject, so far we have used the workaround of manually
>>> renaming the bundle's symbolic name which works perfectly. However is it
>>> possible to know when this fix will be available?
>>>
>>> Regards,
>>>
>>> Himasha Guruge
>>> *Software Engineer*
>>> WS*O2* *Inc.*
>>> Mobile: +94 777459299
>>> himas...@wso2.com
>>>
>>
>>
>>
>> --
>> Sameera Jayasoma,
>> Software Architect,
>>
>> WSO2, Inc. (http://wso2.com)
>> email: same...@wso2.com
>> blog: http://blog.sameera.org
>> twitter: https://twitter.com/sameerajayasoma
>> flickr: http://www.flickr.com/photos/sameera-jayasoma/collections
>> Mobile: 0094776364456
>>
>> Lean . Enterprise . Middleware
>>
>>
>
>
> --
> Himasha Guruge
> *Software Engineer*
> WS*O2* *Inc.*
> Mobile: +94 777459299
> himas...@wso2.com
>
> ___
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


-- 
*Kishanthan Thangarajah*
Associate Technical Lead,
Platform Technologies Team,
WSO2, Inc.
lean.enterprise.middleware

Mobile - +94773426635
Blog - *http://kishanthan.wordpress.com *
Twitter - *http://twitter.com/kishanthan *
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] C5- Datasource startup order issue

2016-03-14 Thread Himasha Guruge
Hi Sameera,

Thanks for the provided info.In bpmn component   to  build  activiti
engine, we require the datasource bundle to be available. Therefore we
tried adding  @Reference annotation  of
org.wso2.carbon.kernel.datasource.core.internal.DataSourceListenerComponent
(for activate method of ActivitiEngineBuilder) but this did not work.

 AFAIU what you suggest is to implement a Listener class that would contain
onJNDIReady() method, which would require other bundles(activiti bundle in
this case) to wait until this method is executed.  Could you please provide
any suggestions on this?

Regards,


On Tue, Mar 15, 2016 at 8:52 AM, Sameera Jayasoma  wrote:

> HI Himasha,
>
> You can refer following documents and samples.
>
> https://github.com/wso2/carbon-jndi
>
> https://github.com/wso2/carbon-datasources/blob/master/sample/src/main/java/org/wso2/carbon/datasource/sample/DataSourceServiceListenerComponent.java
>
> On Tue, Mar 15, 2016 at 4:08 AM, Himasha Guruge  wrote:
>
>> Hi Sameera,
>>
>> With regards to $subject, so far we have used the workaround of manually
>> renaming the bundle's symbolic name which works perfectly. However is it
>> possible to know when this fix will be available?
>>
>> Regards,
>>
>> Himasha Guruge
>> *Software Engineer*
>> WS*O2* *Inc.*
>> Mobile: +94 777459299
>> himas...@wso2.com
>>
>
>
>
> --
> Sameera Jayasoma,
> Software Architect,
>
> WSO2, Inc. (http://wso2.com)
> email: same...@wso2.com
> blog: http://blog.sameera.org
> twitter: https://twitter.com/sameerajayasoma
> flickr: http://www.flickr.com/photos/sameera-jayasoma/collections
> Mobile: 0094776364456
>
> Lean . Enterprise . Middleware
>
>


-- 
Himasha Guruge
*Software Engineer*
WS*O2* *Inc.*
Mobile: +94 777459299
himas...@wso2.com
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] C5- Datasource startup order issue

2016-03-14 Thread Sameera Jayasoma
HI Himasha,

You can refer following documents and samples.

https://github.com/wso2/carbon-jndi
https://github.com/wso2/carbon-datasources/blob/master/sample/src/main/java/org/wso2/carbon/datasource/sample/DataSourceServiceListenerComponent.java

On Tue, Mar 15, 2016 at 4:08 AM, Himasha Guruge  wrote:

> Hi Sameera,
>
> With regards to $subject, so far we have used the workaround of manually
> renaming the bundle's symbolic name which works perfectly. However is it
> possible to know when this fix will be available?
>
> Regards,
>
> Himasha Guruge
> *Software Engineer*
> WS*O2* *Inc.*
> Mobile: +94 777459299
> himas...@wso2.com
>



-- 
Sameera Jayasoma,
Software Architect,

WSO2, Inc. (http://wso2.com)
email: same...@wso2.com
blog: http://blog.sameera.org
twitter: https://twitter.com/sameerajayasoma
flickr: http://www.flickr.com/photos/sameera-jayasoma/collections
Mobile: 0094776364456

Lean . Enterprise . Middleware
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] C5- Datasource startup order issue

2016-03-14 Thread Himasha Guruge
Hi Sameera,

With regards to $subject, so far we have used the workaround of manually
renaming the bundle's symbolic name which works perfectly. However is it
possible to know when this fix will be available?

Regards,

Himasha Guruge
*Software Engineer*
WS*O2* *Inc.*
Mobile: +94 777459299
himas...@wso2.com
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev