Hi Aruna,

This is what we can see in the Service-Component XML.

<reference name="mediation-engine" cardinality="1..n" policy="dynamic"
   interface="org.wso2.carbon.messaging.CarbonMessageProcessor"
bind="addMediationEngine" unbind="removeMediationEngine"/>

Is there anything wrong here ?

I have attached the complete XML file as well.

On Fri, Nov 27, 2015 at 9:31 AM, Senduran Balasubramaniyam <
[email protected]> wrote:

> Hi Aruna,
>
> We are using maven-bundle-plugin with _dsannotations
> yes we also thought that this isn't the correct behavior. What could be
> the reason for this ?
> Could you please suggest us, how to debug the issue
>
> Thanks
> Senduran
>
> On Fri, Nov 27, 2015 at 6:47 PM, Aruna Karunarathna <[email protected]>
> wrote:
>
>> Hi Senduran,
>>
>> Are you using maven-scr-plugin?. Or only the maven-bundle-plugin in your
>> pom.xml?
>>
>> AFAIK this is not the expected behavior, since you are using
>> AT_LEAST_ONE("1..n");  which means wait for at least one service.
>>
>> Regards,
>> Aruna
>>
>> On Fri, Nov 27, 2015 at 5:39 PM, Senduran Balasubramaniyam <
>> [email protected]> wrote:
>>
>>> Hi All,
>>>
>>> We have the following service reference
>>>
>>> @Reference(
>>>         name = "mediation-engine",
>>>         service = CarbonMessageProcessor.class,
>>>         cardinality = ReferenceCardinality.AT_LEAST_ONE,
>>>         policy = ReferencePolicy.DYNAMIC,
>>>         unbind = "removeMediationEngine"
>>> )
>>> protected void addMediationEngine(CarbonMessageProcessor 
>>> carbonMessageProcessor) {
>>>     ContextHolder.getInstance().addEngine(carbonMessageProcessor);
>>> }
>>>
>>>
>>> but the bundle which has this service reference gets activated
>>> regardless of the referencing service (CarbonMessageProcessor service)
>>> Is this the expected behavior.
>>>
>>> Regards
>>> Senduran
>>>
>>> --
>>> *Senduran *
>>> Software Engineer,
>>> WSO2, Inc.;  http://wso2.com/ <http://wso2.com/>
>>> Mobile: +94 77 952 6548
>>>
>>
>>
>>
>> --
>>
>> *Aruna Sujith Karunarathna *| Software Engineer
>> WSO2, Inc | lean. enterprise. middleware.
>> #20, Palm Grove, Colombo 03, Sri Lanka
>> Mobile: +94 71 9040362 | Work: +94 112145345
>> Email: [email protected] | Web: www.wso2.com
>>
>>
>
>
>
> --
> *Senduran *
> Software Engineer,
> WSO2, Inc.;  http://wso2.com/ <http://wso2.com/>
> Mobile: +94 77 952 6548
>



-- 
Regards,
*Shafreen*
Software Engineer
WSO2 Inc
Mobile : 077-556-395-1
<?xml version="1.0"?>
<component name="org.wso2.carbon.messaging.service.MessagingServiceComponent" immediate="true">
  <implementation class="org.wso2.carbon.messaging.internal.MessagingServiceComponent"/>
  <reference name="mediation-engine" cardinality="1..n" policy="dynamic" interface="org.wso2.carbon.messaging.CarbonMessageProcessor" bind="addMediationEngine" unbind="removeMediationEngine"/>
  <reference name="transport-listener" cardinality="1..n" policy="dynamic" interface="org.wso2.carbon.kernel.transports.CarbonTransport" bind="addTransportListener" unbind="removeTransportListener"/>
  <reference name="transport-sender" cardinality="1..n" policy="dynamic" interface="org.wso2.carbon.messaging.TransportSender" bind="addTransportSender" unbind="removeTransportSender"/>
</component>
_______________________________________________
Dev mailing list
[email protected]
http://wso2.org/cgi-bin/mailman/listinfo/dev

Reply via email to