This issue has been created
There are 2 updates.
 
 
Change Request Application / cid:jira-generated-image-avatar-195511a9-ac61-4c0f-b2f6-1c3b21cdbf15 CRAPP-454 Open

Change request events are not recorded anymore after upgrading the application

 
View issue   ยท   Add comment
 

Issue created

 
cid:jira-generated-image-avatar-f9730ee6-fdc7-47a8-948f-dcd5c366d61b Simon Urli created this issue on 12/Nov/26 16:02
 
Summary: Change request events are not recorded anymore after upgrading the application
Issue Type: cid:jira-generated-image-avatar-195511a9-ac61-4c0f-b2f6-1c3b21cdbf15 Bug
Affects Versions: 1.16, 1.26
Assignee: Unassigned
Components: notifications
Created: 12/Nov/26 16:02
Priority: cid:jira-generated-image-static-major-60e0e16a-89ca-4968-8d84-801b6fd516e5 Major
Reporter: Simon Urli
Description:

Problem

After upgrading the Change Request application on a running instance, the change request events can stop being recorded: the timeline of the change requests (Description tab) doesn't show any new event anymore (creation, status change, review, comment...) and the related notifications are not sent. Only a restart of the instance makes them work again, and the events triggered in the meantime are lost.

This happened on xwiki.org after the upgrade to 1.26 on 2026-11-03: no changerequest.* event has been stored since then, while the other events are stored normally. The same symptom was reported in CRAPP-374 (and CRAPP-373) on 1.16 without its cause being identified.

Cause

At the end of an extension job that upgrades a JAR extension, all the JAR extensions of the root namespace are unloaded and loaded again, one JAR after the other. When the components of a JAR are registered, the observation manager instantiates its event listeners right away, and if that fails it logs the following error in the job log and ignores the listener until the next restart:

Failed to lookup the Event Listener [ChangeRequestCreatedEventListener] corresponding to the Component registration event for [...]. Ignoring the event

The listeners of application-changerequest-notifications (through ChangeRequestRecordableEventNotifier) require components implemented in application-changerequest-default, such as DocumentReferenceResolver<ChangeRequest> or ChangeRequestStorageManager. However application-changerequest-notifications only depends on application-changerequest-default with the test scope, so nothing ensures that application-changerequest-default is loaded first: when it's loaded after, all the notifications listeners are dropped.

The issue doesn't happen at startup, since the listeners are only instantiated once all the extensions are loaded.

 
 

2 updates

 
cid:jira-generated-image-avatar-f9730ee6-fdc7-47a8-948f-dcd5c366d61b Changes by Simon Urli on 12/Nov/26 16:02
 
Fix Version: 1.26.1
Assignee: Simon Urli