Uploaded image for project: 'Commons Configuration'
  1. Commons Configuration
  2. CONFIGURATION-420

OverrideCombiner seems to ignore list nodes

VotersWatch issueWatchersLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Invalid
    • 1.6
    • 1.7
    • Interpolation
    • None

    Description

      When using OverrideCombiner it seems to ignore any list nodes and always return properties/values for list node from the overridden file. See the attached files for an example of what I mean. The following code always returns the values from config-custom even if list-nodes mentions that the sysprops node is a list-node.

      URL fileURL = TestConfig.class.getResource("config-conf.xml");

      try

      { DefaultConfigurationBuilder configBuilder = new DefaultConfigurationBuilder(fileURL); CombinedConfiguration config = configBuilder.getConfiguration(true); System.out.println(config.getString("sysprops/testkey")); System.out.println(config.getString("configprops/testkey1")); }

      catch (ConfigurationException e)

      { e.printStackTrace(); }

      Attachments

        1. config-custom.xml
          0.2 kB
          Aniruddh Chitre
        2. config-conf.xml
          0.8 kB
          Aniruddh Chitre
        3. config.xml
          0.2 kB
          Aniruddh Chitre

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            Unassigned Unassigned
            aniruddhc Aniruddh Chitre
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment