Description
Steps to reproduce
- Create subwiki
- Customize the subwiki XWikiPreferences, for instance by removing the "comment" right granted by default to XWikiAdminGroup
- Export the customized XWikiPreferences
- Create a Maven custom flavor project "myflavor"
- In "myflavor" POM, add a dependency on org.xwiki.platform:xwiki-platform-distribution-flavor-wiki
- Add the custom XWikiPreferences to the myflavor project in src/main/resources
- Build "myflavor" and edit XWiki's META-INF/extensions.xed to declare this flavor as a known flavor.
- Create a subwiki based on "myflavor"
- Go back to the WikiManager and create a second subwiki based on "myflavor".
Actual result
For the first subwiki,the installation goes as expected. However fot the second one, the wiki creation log contains an error "Collision found on object XWiki XWikiPreferences" and the custom XWikiPreferences is not deployed. Page XWikiPreferences has the following history:
Version coming from extension Base Flavor Application 14.4.2 Rollback Version coming from extension MyFlavor 1.0-SNAPSHOT Rollback 3.1 Admin 2022/08/08 16:28 Install extension [org.xwiki.contrib:myflavor/1.0-SNAPSHOT] Current version Delete 2.1 Admin 2022/08/08 16:28 Install extension [org.xwiki.platform:xwiki-platform-distribution-ui-base/14.4.2] Rollback Delete 1.1 Admin 2022/08/08 16:27 Synced mandatory class property definitions to default values Rollback Delete
On the first subwiki, the history of XWikiPreferences does not contain entry "org.xwiki.platform:xwiki-platform-distribution-ui-base".
Expected result
No object collision error is raised on flavor deployment and the custom XWikiPreferences is deployed in subwiki.
Note that when proceeding in two steps: 1) wiki provisioning with empty flavor, 2) custom flavor installation, no error is raised and the custom XWikiPreferences is installed as expected.
Attachments
Issue Links
- depends on
-
XCOMMONS-2491 Allow accessing the current extension session
- Closed
- is caused by
-
XWIKI-19897 xwiki-platform-search-ui and xwiki-platform-search-solr-ui end up installed as root in the standard flavor
- Closed
-
XWIKI-19880 Subwiki created from flavor have the wrong pages author when the instance contains XAR extensions installed on root namespace
- Closed