bootstrap: ordering files by filename length isnt always very nice
------------------------------------------------------------------

                 Key: MAGNOLIA-1541
                 URL: http://jira.magnolia.info/browse/MAGNOLIA-1541
             Project: Magnolia
          Issue Type: Bug
          Components: core
    Affects Versions: 3.1 M1, 3.0.2
            Reporter: Grégory Joseph
         Assigned To: Sameer Charles


Consider the following bootstrap files:

config.modules.test.templates.babababababababababba.xml
config.modules.test.templates.mail-form.xml
config.modules.test.templates.redir.xml
config.modules.test.templates.std.xml
config.modules.test.templates.tralalalala.xml
config.modules.test.templates.utility.xml

With the current BootstrapFilesComparator, they will be ordered, bootstrapped 
and appear in the tree in the following order: std, redir, utility, mail-form, 
tralalalala and babababababababababba, which admitedly doesn't make much sense.

The reason why the files are ordered by length is an easy hack to bootstrap 
parent files first (ie config.modules.test.templates.xml would be bootstrapped 
before any of the above)

I added BootstrapFilesComparatorTest.testFilesAreOrderedByFileNameLength() to 
illustrate some of these issues.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://jira.magnolia.info/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira



----------------------------------------------------------------
for list details see
http://www.magnolia.info/en/developer.html
----------------------------------------------------------------

Reply via email to