Have Diagram Application (Pro) 1.10 installed on farm
Create a diagram with clipart shapes
Upgrade on farm the application to version 1.15.2
Observe the progress displayed in Extension Manager
Observe the created diagram page
Results
The following error appears, but the application is upgraded correctly:
Failed to send event [org.xwiki.extension.event.ExtensionUpgradedEvent@4cd30ffd] to listener [com.xwiki.diagram.internal.DiagramApplicationListener@766a17a5]
class java.lang.NullPointerException: null
at com.xwiki.diagram.internal.DiagramApplicationListener.getTargetWikis(DiagramApplicationListener.java:80)
at com.xwiki.diagram.internal.DiagramApplicationListener.onEvent(DiagramApplicationListener.java:75)
at org.xwiki.observation.internal.DefaultObservationManager.notify(DefaultObservationManager.java:304)
at org.xwiki.observation.internal.DefaultObservationManager.notify(DefaultObservationManager.java:269)
at org.xwiki.extension.job.internal.AbstractExtensionJob.installExtension(AbstractExtensionJob.java:339)
at org.xwiki.extension.job.internal.AbstractExtensionJob.applyAction(AbstractExtensionJob.java:209)
at org.xwiki.extension.job.internal.AbstractExtensionJob.applyActions(AbstractExtensionJob.java:157)
at org.xwiki.extension.job.internal.InstallJob.runInternal(InstallJob.java:154)
at org.xwiki.job.AbstractJob.runInContext(AbstractJob.java:206)
at org.xwiki.job.AbstractJob.run(AbstractJob.java:189)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)
This error appears in EM despite the version from which the upgrade is done.
After upgrade, the created page is broken:
The text was updated successfully, but these errors were encountered:
The unapplied migration will affect only diagrams created before Diagram Application version 1.11, but the error in EM will appear for any upgrade
oanalavinia
changed the title
Error in EM while upgrading the application, leading to unapplied migration
Error in EM while upgrading on farm the application, leading to unapplied migration
Oct 9, 2020
oanalavinia
added a commit
to oanalavinia/application-diagram
that referenced
this issue
Oct 9, 2020
Note that to have the fix to the problem, two diagram upgrades will be needed, where the first upgrade is to a version >= 1.15.3 (the fix version).
The reason is that a component that listens to the upgrade operation is the provider of the error, and while doing the first upgrade the old component will be the one registered. Only on a second upgrade the new listener (that was fixed in the previous upgrade) will be the one registered.
Steps to reproduce
Results
The following error appears, but the application is upgraded correctly:
This error appears in EM despite the version from which the upgrade is done.
After upgrade, the created page is broken:

The text was updated successfully, but these errors were encountered: