Description
Steps to reproduce:
1.Create a node and save.
2. Create sns node before the first sns and save.
Autoexport exports configuration in the following order:
/config:
jcr:primaryType: nt:unstructured
/sns[2]:
jcr:primaryType: nt:unstructured
/sns:
.meta:order-before: sns[2]
jcr:primaryType: nt:unstructured
Stacktrace:
[INFO] [talledLocalContainer] 15:28:08 INFO autoexport is processing changes...
[INFO] [talledLocalContainer] 07.09.2017 15:28:08 ERROR pool-9-thread-1 [ConfigurationServiceImpl.updateBaselineForAutoExport:382] Failed to update the Configuration baseline after auto-export
[INFO] [talledLocalContainer] java.lang.IllegalStateException: gettingstarted/gettingstarted/gettingstarted-repository-data-application [config: main.yaml] defines node '/config/sns[2]', but no sibling named 'sns[1]' was found
[INFO] [talledLocalContainer] at org.onehippo.cm.model.impl.tree.ConfigurationTreeBuilder.createChildNode(ConfigurationTreeBuilder.java:441) ~[hippo-configuration-management-model-1.0.1-SNAPSHOT.jar:1.0.1-SNAPSHOT]
[INFO] [talledLocalContainer] at org.onehippo.cm.model.impl.tree.ConfigurationTreeBuilder.mergeNode(ConfigurationTreeBuilder.java:271) ~[hippo-configuration-management-model-1.0.1-SNAPSHOT.jar:1.0.1-SNAPSHOT]
[INFO] [talledLocalContainer] at org.onehippo.cm.model.impl.tree.ConfigurationTreeBuilder.push(ConfigurationTreeBuilder.java:134) ~[hippo-configuration-management-model-1.0.1-SNAPSHOT.jar:1.0.1-SNAPSHOT]
[INFO] [talledLocalContainer] at java.util.ArrayList.forEach(ArrayList.java:1249) ~[?:1.8.0_131]
[INFO] [talledLocalContainer] at org.onehippo.cm.model.impl.ConfigurationModelImpl.buildConfiguration(ConfigurationModelImpl.java:235) ~[hippo-configuration-management-model-1.0.1-SNAPSHOT.jar:1.0.1-SNAPSHOT]
[INFO] [talledLocalContainer] at org.onehippo.cm.model.impl.ConfigurationModelImpl.build(ConfigurationModelImpl.java:204) ~[hippo-configuration-management-model-1.0.1-SNAPSHOT.jar:1.0.1-SNAPSHOT]
[INFO] [talledLocalContainer] at org.onehippo.cm.model.impl.ConfigurationModelImpl.mergeWithSourceModules(ConfigurationModelImpl.java:457) ~[hippo-configuration-management-model-1.0.1-SNAPSHOT.jar:1.0.1-SNAPSHOT]
[INFO] [talledLocalContainer] at org.onehippo.cm.engine.ConfigurationBaselineService.updateBaselineModules(ConfigurationBaselineService.java:224) ~[hippo-repository-engine-5.0.1-SNAPSHOT.jar:5.0.1-SNAPSHOT]
[INFO] [talledLocalContainer] at org.onehippo.cm.engine.ConfigurationServiceImpl.updateBaselineForAutoExport(ConfigurationServiceImpl.java:378) ~[hippo-repository-engine-5.0.1-SNAPSHOT.jar:5.0.1-SNAPSHOT]
[INFO] [talledLocalContainer] at org.onehippo.cm.engine.autoexport.EventJournalProcessor.exportChangesModule(EventJournalProcessor.java:822) ~[hippo-repository-engine-5.0.1-SNAPSHOT.jar:5.0.1-SNAPSHOT]
[INFO] [talledLocalContainer] at org.onehippo.cm.engine.autoexport.EventJournalProcessor.processEvents(EventJournalProcessor.java:424) ~[hippo-repository-engine-5.0.1-SNAPSHOT.jar:5.0.1-SNAPSHOT]
[INFO] [talledLocalContainer] at org.onehippo.cm.engine.autoexport.EventJournalProcessor.tryProcessEvents(EventJournalProcessor.java:315) ~[hippo-repository-engine-5.0.1-SNAPSHOT.jar:5.0.1-SNAPSHOT]
[INFO] [talledLocalContainer] at org.onehippo.cm.engine.autoexport.EventJournalProcessor.lambda$new$0(EventJournalProcessor.java:186) ~[hippo-repository-engine-5.0.1-SNAPSHOT.jar:5.0.1-SNAPSHOT]
[INFO] [talledLocalContainer] at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:1.8.0_131]
[INFO] [talledLocalContainer] at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308) [?:1.8.0_131]
[INFO] [talledLocalContainer] at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180) [?:1.8.0_131]
[INFO] [talledLocalContainer] at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294) [?:1.8.0_131]
[INFO] [talledLocalContainer] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) [?:1.8.0_131]
[INFO] [talledLocalContainer] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) [?:1.8.0_131]
[INFO] [talledLocalContainer] at java.lang.Thread.run(Thread.java:748) [?:1.8.0_131]
[INFO] [talledLocalContainer] 15:28:08 INFO autoexport update complete