Details
-
Bug
-
Resolution: Unresolved
-
Minor
-
16.10.9
-
None
-
Unknown
-
Description
Steps to reproduce
- Start XWiki with the extension index enabled (default)
- Stop XWiki while the extension index job is validating extensions (e.g. right after startup)
Expected
XWiki stops without error; the extension index is updated again at the next start.
Actual
An error is logged for each extension the job still validates after the extension index store is disposed:
ERROR o.x.e.i.i.j.ExtensionIndexJob - Failed to validate extension with if [org.xwiki.platform:...] on namespace [...] org.infinispan.commons.IllegalLifecycleStateException: ISPN000323: Cache 'extension.index' is in 'TERMINATED' state and so it does not accept new invocations. Either restart it or recreate the cache container. ... at org.xwiki.cache.infinispan.internal.InfinispanCache.remove(InfinispanCache.java:81) at org.xwiki.extension.index.internal.ExtensionIndexStore.commit(ExtensionIndexStore.java:245) at org.xwiki.extension.index.internal.job.ExtensionIndexJob.validateExtensions(ExtensionIndexJob.java:555) at org.xwiki.extension.index.internal.job.ExtensionIndexJob.validateLastExtensions(ExtensionIndexJob.java:231) at org.xwiki.extension.index.internal.job.ExtensionIndexJob.runInternal(ExtensionIndexJob.java:214)
Analysis
The extension index job runs in its own job thread and nothing stops it when XWiki stops: ExtensionIndexJobScheduler#dispose() only stops its scheduling executor. ExtensionIndexStore#dispose() then disposes the extension.index cache (added by XWIKI-23322), and every following store call of the job fails; ExtensionIndexJob#validateExtensions logs each failure as an error.
Found in the logs of the flavor UI functional tests on CI (master build 9025), when XWiki is stopped at the end of the tests.
Attachments
Issue Links
- relates to
-
XWIKI-25215 An error is logged when stopping XWiki while the Solr index synchronization is waiting for the indexing to be applied
-
- Closed
-
-
XWIKI-23322 Add a cache to the extension index
-
- Closed
-