This issue has been created
There are 4 updates.
 
 
XWiki Platform / cid:jira-generated-image-avatar-ba727379-6ed1-49cf-945b-c46b16623e50 XWIKI-25215 Open

An error is logged when stopping XWiki while the Solr index synchronization is waiting for the indexing to be applied

 
View issue   ยท   Add comment
 

Issue created

 
cid:jira-generated-image-avatar-bcb3ab4e-13ba-4ff1-ab8a-eadb3ef87859 Simon Urli created this issue on 08/Oct/26 14:19
 
Summary: An error is logged when stopping XWiki while the Solr index synchronization is waiting for the indexing to be applied
Issue Type: cid:jira-generated-image-avatar-ba727379-6ed1-49cf-945b-c46b16623e50 Bug
Affects Versions: 17.8.0
Assignee: Unassigned
Components: Search - Solr
Created: 08/Oct/26 14:19
Priority: cid:jira-generated-image-static-major-cc190a51-092e-46df-a56d-b3a7aa570747 Major
Reporter: Simon Urli
Description:

Steps to reproduce

  1. Start XWiki on a wiki large enough for the Solr index synchronization executed at startup to take some time (or with an empty Solr index)
  2. Stop XWiki while that synchronization is still running

Expected

XWiki stops without error. The synchronization is interrupted and is executed again at the next startup.

Actual

The following error is logged while stopping:

ERROR o.x.s.s.i.j.IndexerJob - Exception thrown during job execution
java.util.concurrent.ExecutionException: org.xwiki.index.IndexException: Indexing stopped.
	at java.base/java.util.concurrent.CompletableFuture.reportGet(CompletableFuture.java:396)
	at java.base/java.util.concurrent.CompletableFuture.get(CompletableFuture.java:2073)
	at org.xwiki.search.solr.internal.job.IndexerJob.updateSolrIndex(IndexerJob.java:196)
	at org.xwiki.search.solr.internal.job.IndexerJob.updateSolrIndex(IndexerJob.java:146)
	at org.xwiki.search.solr.internal.job.IndexerJob.runInternal(IndexerJob.java:122)
	at org.xwiki.job.AbstractJob.runInContext(AbstractJob.java:250)
	at org.xwiki.job.AbstractJob.run(AbstractJob.java:227)
Caused by: org.xwiki.index.IndexException: Indexing stopped.
	at org.xwiki.search.solr.internal.DefaultSolrIndexer.stopIndexerThread(DefaultSolrIndexer.java:507)

Cause

Since XWIKI-15166, the indexer job waits for the indexing to be applied (this.indexer.waitReady().get()) before removing the invalid entries. When XWiki stops, DefaultSolrIndexer completes all the pending waitReady() futures with IndexException("Indexing stopped.") (since XWIKI-22323), which the job propagates as a failure.

This is visible on the functional tests which stop XWiki soon after startup, e.g. SuggestTest (distribution flavor misc tests) and the distribution flavor storage tests.

 
 

4 updates

 
cid:jira-generated-image-avatar-bcb3ab4e-13ba-4ff1-ab8a-eadb3ef87859 Changes by Simon Urli on 08/Oct/26 14:19
 
Fix Version: 18.9.0-rc-1
Fix Version: 17.10.14
Fix Version: 18.4.7
Assignee: Simon Urli