felix-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Carsten Ziegeler (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (FELIX-5693) Improve persistent manager handling
Date Fri, 22 Sep 2017 05:43:00 GMT

    [ https://issues.apache.org/jira/browse/FELIX-5693?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16175944#comment-16175944

Carsten Ziegeler commented on FELIX-5693:

[~fhoelting] Thanks for the feedback.
Look at PersistenceManagerTracker#L77 - it is using the configured property in the filter
expression for the service tracker. So if the property is configured to something different
than "file", the FilePersistenceManager is not used at all and it is waiting for the named
PM to arrive. I did a quick test and this seems to work.
It is true, that the service ranking is then used, but only for all PMs with exactly that
name - you should usually have only one with a unique name. But if you have more than one,
you still get a stable result, independent of start order but based on service ranking. So
this is reliable.
Could you please recheck?

> Improve persistent manager handling
> -----------------------------------
>                 Key: FELIX-5693
>                 URL: https://issues.apache.org/jira/browse/FELIX-5693
>             Project: Felix
>          Issue Type: Improvement
>          Components: Configuration Admin
>            Reporter: Carsten Ziegeler
>            Assignee: Carsten Ziegeler
>             Fix For: configadmin-1.9.0
>         Attachments: case1_with_felix.cm.pm.txt, case2_without_felix.cm.pm.txt
> The current handling of persistence managers is a little bit fragile and not really deterministic.
> I propose the following enhancements:
> - Persistence managers can be registered with a "name" service property. The FilePersistenceManager
gets a name, e.g. "file"
> - we add a new framework property configuration - if that's empty or not there, CM acts
as today
> - if a value is configured, it's interpreted as a comma separated list of names. This
list of names makes up the PMs to be used by the implementation. All of them must be registered
and only these are used.
> - the PMs are used in the order they are specified in the list
> With this we have deterministic behaviour and full control while the default ootb behaviour
is still maintained. 

This message was sent by Atlassian JIRA

View raw message