[
https://issues.apache.org/jira/browse/SLING-4915?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Konrad Windszus resolved SLING-4915.
------------------------------------
Resolution: Fixed
Fixed by [r1729981|http://svn.apache.org/r1729981].
> Order of sub-nodes is not maintained in case of a merge
> -------------------------------------------------------
>
> Key: SLING-4915
> URL: https://issues.apache.org/jira/browse/SLING-4915
> Project: Sling
> Issue Type: Bug
> Components: ResourceResolver
> Affects Versions: Resource Merger 1.2.10
> Reporter: Radu Cotescu
> Assignee: Konrad Windszus
> Priority: Minor
> Fix For: Resource Merger 1.3.2
>
>
> Given two content structures that should be merged by the Resource Merger, if
> the second tree contains all the sub-nodes of the first tree, a new node
> added in the second tree will always be added towards the end, irrespective
> of its position in the sub-node tree.
> Example:
> {noformat}
> /libs/p1/components/c1
> node1
> node2
> node3
> /libs/p2/components/c1 (sling:resourceSuperType=/libs/p1/components/c1)
> node1
> node4
> node2
> node3
> {noformat}
> When iterating over the child resources of {{/libs/p2/components/c1}},
> {{node4}} will be the last child in the iteration instead of the second.
> The workaround is to not define the redundant nodes and add the
> {{sling:orderBefore}} property on {{node4}}, however this should be handled
> by default by the merger.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)