[xwiki-devs] Is it possible to upgrade xwiki extension to a new version automatically?
I use InstalledExtensionScriptService class to retrieve a list of installed extensions. I would like automatically upgrade RTWysiwyg (or any other) extension if the current version less than the version in my jar file (hardcoded). When I try to use ExtensionManagerScriptService class to uninstall existing extension and then install the new one XWiki freezes. I studied xwiki docs and think it can be a conflict. What should I do? -- View this message in context: http://xwiki.475771.n2.nabble.com/Is-it-possible-to-upgrade-xwiki-extension-... Sent from the XWiki- Dev mailing list archive at Nabble.com.
On Thu, Apr 14, 2016 at 5:25 PM, abtv <andreybutov@mail.ru> wrote:
I use InstalledExtensionScriptService class to retrieve a list of installed extensions. I would like automatically upgrade RTWysiwyg (or any other) extension if the current version less than the version in my jar file (hardcoded). When I try to use ExtensionManagerScriptService class to uninstall existing extension and then install the new one XWiki freezes. I studied xwiki docs and think it can be a conflict. What should I do?
If you have a conflict it means you modified a standard document. If you disabled interactive mode in the install request it won't bother you again but if you mess with the standard documents you might still have bad surprises... You can look at http://extensions.xwiki.org/xwiki/bin/view/Extension/Extension+Script+Module... for various example of how to use the scrip API.
-- View this message in context: http://xwiki.475771.n2.nabble.com/Is-it-possible-to-upgrade-xwiki-extension-... Sent from the XWiki- Dev mailing list archive at Nabble.com. _______________________________________________ devs mailing list devs@xwiki.org http://lists.xwiki.org/mailman/listinfo/devs
-- Thomas Mortagne
Should I uninstall my extension before installing the new one? Or I can just call install functions with the new version of extension? And what about dependencies? Will it resolve and reinstall all the dependencies of the extension? -- View this message in context: http://xwiki.475771.n2.nabble.com/Is-it-possible-to-upgrade-xwiki-extension-... Sent from the XWiki- Dev mailing list archive at Nabble.com.
If you install a new version it will automatically replace any matching extension and upgrade it but again if you modified standard pages it will try to merge it and you might not get what you expect in the end in non interactive mode. On Thu, Apr 14, 2016 at 6:57 PM, abtv <andreybutov@mail.ru> wrote:
Should I uninstall my extension before installing the new one? Or I can just call install functions with the new version of extension? And what about dependencies? Will it resolve and reinstall all the dependencies of the extension?
-- View this message in context: http://xwiki.475771.n2.nabble.com/Is-it-possible-to-upgrade-xwiki-extension-... Sent from the XWiki- Dev mailing list archive at Nabble.com. _______________________________________________ devs mailing list devs@xwiki.org http://lists.xwiki.org/mailman/listinfo/devs
-- Thomas Mortagne
participants (2)
-
abtv -
Thomas Mortagne