Hello,
Could you please suggest solution for the following issue:

Description:
There are number of implementations of MetadataProvider interface, these
implementations are collected into map as described below, and then used by
application logic 

@Reference(name = "metadataProvider", strategy = ReferenceStrategy.EVENT,
policy = ReferencePolicy.DYNAMIC, referenceInterface =
MetadataProvider.class, cardinality =
ReferenceCardinality.OPTIONAL_MULTIPLE)

        
protected void bindMetadataProvider(MetadataProvider mp) {
   providerMap.put(mp.getType(), mp);
}
        
protected void unbindMetadataProvider(MetadataProvider mp) {
   providerMap.remove(mp.getType());
}


Task:
I would like to decorate/intercept one of the implementation's method.  
If you do: providerMap.get(“type”).callMethod(), callMethod() should be
intercepted.

Issue:
AspectService approach doesn’t work here.  When I created  AspectService for 
MetadataProvider interface, “bind” registered all implementations + aspect
services for all implementations. 

Any ideas how to make it?

Thanks,
Vladimir

-- 
View this message in context: 
http://old.nabble.com/AspectService-for-dynamic-reference-tp31145479p31145479.html
Sent from the Apache Felix - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to