commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Oliver Heger (JIRA)" <>
Subject [jira] Commented: (CONFIGURATION-264) SubnodeConfiguration does not see reloads of its parent configuration
Date Mon, 20 Aug 2007 18:29:30 GMT


Oliver Heger commented on CONFIGURATION-264:

Unfortunately, with the configurationsAt() method it is not as easy.

The problem is that for making a subnode configuration aware of updates, the exact key to
the root node must be known. This is not the case for the configurationsAt() method because
the passed in key refers to an arbitrary number of nodes. How the single nodes of this set
can be uniquely identified, depends on the currently used expression engine. Currently the
ExpressionEngine interface does not provide a method for retrieving the exact key of a passed
in node. So there is no chance to obtain this information.

In the next major release I will probably add such a method to the ExpressionEngine interface.
Then this problem could be solved.

> SubnodeConfiguration does not see reloads of its parent configuration
> ---------------------------------------------------------------------
>                 Key: CONFIGURATION-264
>                 URL:
>             Project: Commons Configuration
>          Issue Type: Bug
>    Affects Versions: 1.4
>            Reporter: Oliver Heger
>            Assignee: Oliver Heger
>             Fix For: 1.5
> The problem can be reproduced as follows:
> 1 config = new XMLConfiguration("c:\\conf.xml");
> 2 config.setReloadingStrategy(new FileChangedReloadingStrategy());
> 3 SubnodeConfiguration parentItemConfig = config.configurationAt("parent-item");
> 4 String ss2 = parentItemConfig.getString("sub-item");
> 5 //Now, <sub-item> node value changes to "new_value"
> 6 ss2 = parentItemConfig.getString("sub-item"); // still returns old_value

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message