Update issue with product containing fragments [message #1833066] |
Thu, 01 October 2020 16:15 |
Aleksei Airapetov Messages: 13 Registered: December 2019 |
Junior Member |
|
|
Hello,
I have a feature-based product which is installed and updated from p2 repository. Among others my product contains Babel features with localization plugin fragments.
Recently I faced an issue with updating to a newer version of the product - after performing setup tasks the new version of the product simply wasn't available.
After a few experiments I realized that the reason is that the new version of the p2 contains a new version of Babel features.
I also tried setting a version range to the product version in my setup file - my product was updated to the new version, offered to restart, and then crashed with an exception like this:
java.lang.IllegalStateException: Module has been uninstalled.
at org.eclipse.osgi.internal.framework.EquinoxBundle.checkValid(EquinoxBundle.java:1000)
at org.eclipse.osgi.internal.framework.EquinoxBundle.getEntry(EquinoxBundle.java:699)
at org.eclipse.core.internal.runtime.FindSupport.findInFragments(FindSupport.java:254)
at org.eclipse.core.internal.runtime.FindSupport.findNL(FindSupport.java:223)
at org.eclipse.core.internal.runtime.FindSupport.find(FindSupport.java:112)
at org.eclipse.core.internal.runtime.FindSupport.find(FindSupport.java:64)
at org.eclipse.core.runtime.FileLocator.find(FileLocator.java:90)
After debugging, I found out that the module on which the exception is thrown is the localization fragment for jface (but the problem is not in a specific fragment, if you delete a jface localization fragment, then checking of the next fragments will also throw such an exception).
However, if you try to launch the product again after that, it will launch without any problems.
So I would like to ask for advice - has anyone encountered such strange behavior when updating plugin fragments? Can this behavior be related specifically to Babel or is it generally related to plugin fragments? Are there any known problems similar to mine, or any common practices for organizing fragments in p2/products that I might have missed?
[Updated on: Thu, 01 October 2020 16:15] Report message to a moderator
|
|
|
|
|
|
Re: Update issue with product containing fragments [message #1833153 is a reply to message #1833132] |
Sun, 04 October 2020 17:20 |
Aleksei Airapetov Messages: 13 Registered: December 2019 |
Junior Member |
|
|
Actually the -clean flag seems to be useful - after I added it to .ini file, when I try to update the product, it no longer throws any exceptions when restarting.
Also the bug you mentioned is claimed to be fixed, so I guess I should try to update to a newer version of p2 plugins and try to make it work without the flag.
Concerning not finding updates without version range:
- Product qualifier is indeed higher in p2 repo which I'm trying to update to
- I suspect that updating the version of Babel features is the cause of the issue, as I tried to update to an identical version of the product but with the same version of Babel and everything was just fine - updates were being found without any version ranges specified
- Some time ago I tried to debug the update mechanism to understand the reason and I realized that the product sees available new versions of plugins, but however when resolving dependencies makes a choice in favor of the old already installed version of product. I still didn't understand what the problem was because I got to the Sat4j level, where human-readable plug-in names turned into "zeros and ones", and it was difficult to understand where the algorithm turns the wrong way.
[Updated on: Sun, 04 October 2020 17:41] Report message to a moderator
|
|
|
Powered by
FUDForum. Page generated in 0.03994 seconds