Uninstalling Extensions Globally

Hi,

The TLDR version of my question is, if I choose the Uninstall from farm option for the following apps/extensions, should they also be removed from subwikis?

  • Tour Application
  • Bootstrap Tour
  • Sandbox Application
  • Invitation Application
  • Share Page Application
  • Help Application

Details / Steps

What I’m experiencing is that for each of the applications above, when I choose the Uninstall from farm option, a red error message appears in the log output:

Extension [****] is not installed

I continue, the app is removed from the Top-Level wiki but, if I go to the subwiki, the apps are still installed.

Steps

XWiki: 13.10.5

  1. Fresh install XWiki
  2. Complete Distribution Wizard, selecting the Standard Flavour
  3. Add a subwiki, selecting the Standard Subwiki Flavour and mark the subwiki as a Template.
  4. Wait for subwiki to be created.
  5. Go back to top-level wiki.
  6. Uninstall the applications above using the Uninstall from farm option.
    • See red error message in log output.
  7. Go to subwiki
    • The tour will still load but if you go to the extensions management and search for the ones above, they will appear as being installed.

As I think of the process now, I can’t remember whether I’ve gone to the subwiki once it has been created or whether after the creation process says completed I go straight to the extension management to remove the apps/extensions. If I get chance, I’ll try out both the exact instructions above and the steps above but with visiting the subwiki after it’s created.

I make the point about visiting the subwiki because, when I was doing a v12 to v13 upgrade, I found that after the upgrade the apps above had been reinstalled. As such, I went to uninstall them again from the Top level wiki; however, when going to each subwiki, the apps were still there. What I found was that the upgrade process didn’t really “finish” on a subwiki until it was actually visited. The finishing of the upgrade process also reinstalled all the apps, even if they weren’t installed in the top-level wiki.

Thanks in advance,
Alex

I’ve just tried looking for another extension to uninstall.

From the top-level wiki, if I try the Uninstall from farm option, I get the following output:

Screenshot 2022-08-05 at 11.27.36

If I don’t continue but instead go to a subwiki and look for JCaptcha Application, it is listed (please excuse the misaligned boxes, the subwiki is using a different theme and I’m still working out the kinks :slight_smile: )

Screenshot 2022-08-05 at 11.28.11

If I proceed to uninstall the JCaptcha Application from the top-level wiki, I get the following screen:

Screenshot 2022-08-05 at 11.32.37

Which does not list the subwiki for documents to be removed.

The uninstallation proceeds without issue.

If I then go to the subwiki and search for JCapture, it’s still listed as installed as the screenshot from my previous comment.

Right now “Uninstall from farm” is just the mirror of “Install on farm” which means that it only deal with extensions specifically installed that way. But indeed, the fact that it’s always proposed even when it’s not how the extension was installed is quite misleading and should be fixed.

But I agree we should probably instead change a bit the behavior to not only look at the root namespace but also all wikis to find extensions with the same ID and version.

Thanks @tmortagne. I’m not 100% confident and maybe it’s just coincidence that I’ve always done things in a certain way but, I feel like this behaviour changed between v12 and v13. In v12, for apps that are part of the standard flavour, when you uninstalled from farm in the top-level wiki it did indeed do what you suggest and find the same app/extension in subwikis and uninstall if present.

I’ve had a look in Jira for all the 13.x versions and I can’t see anything obvious that would indicate a change in behaviour but that might just mean the behaviour hasn’t changed or, I’m not seeing the wood for the trees.

Anyway, I now know what the expected behaviour is in v13 at least and I can go from there.

Thanks again @tmortagne

I doubt this behavior changed, but one thing to have in mind in the specific case of a flavor install through the Distribution Wizard is that:

  • XAR extensions are install at wiki level (so uninstall from farm does not work)
  • JAR extensions are install at root level (so uninstall from farm works)

Ah ok, thanks, that might explain it then.

Cheers