[ 
https://issues.apache.org/jira/browse/OAK-3815?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Chetan Mehrotra resolved OAK-3815.
----------------------------------
       Resolution: Won't Fix
    Fix Version/s:     (was: 1.3.14)

Had a offline discussion with [~mduerig] on this. Tracer was meant to be a poor 
man service registry to allow Oak to work in OSGi and non OSGi env easily. 
Adding support for refresh callback would make it closer to OSGi side which 
then brings in lots of complexity around implementation.

Another aspect is that support for refresh indicates that Oak logic internal 
support such dynamic changes without restart of major component. Which is not 
the case (like seen with SecurityProvider)

So would look for another approach in LuceneIndexProvider side and resolve this 
as Wont Fix

> Add refresh callback support to Tracker
> ---------------------------------------
>
>                 Key: OAK-3815
>                 URL: https://issues.apache.org/jira/browse/OAK-3815
>             Project: Jackrabbit Oak
>          Issue Type: Improvement
>          Components: core
>            Reporter: Chetan Mehrotra
>            Assignee: Chetan Mehrotra
>            Priority: Minor
>         Attachments: OAK-3815-v1.patch
>
>
> Currently the {{Tracker}} only has access to list of registered services but 
> there is no way to know if the services have changed and one has to re obtain 
> the set of services. For certain usecases its desirable to know (get 
> notified) if the set of services registered against a specific type have 
> changed. 
> For e.g. in OAK-3576 the services are to be registered against set of 
> NodeTypes and each service provides set of nodeTypes it support. Creating 
> that structure (nodeType -> service) is to be avoided on the critical path.
> So far Tracker serves the purpose well. One can just open the tracker and get 
> the list of services and create that nodeType -> service mapping. However in 
> case of OSGi (or in other modes also) if a new service is registered there is 
> no way currently to get notified. As of now one needs to have reference 
> property added to some OSGi component with bind and unbind callbacks. Given 
> we already make use of {{ServicetTracker}} and do get notified when services 
> get updated we should easily be able to make use of that.
> For such cases I would like to propose registering a callback which should 
> get notified if there is some change in set of services registered against a 
> specific type. Then one can register the callback while creating the Tracker 
> instance 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to