Details
-
Bug
-
Resolution: Unresolved
-
Major
-
None
-
5.1
-
None
-
Unknown
-
Description
Problem
The Solr indexer keeps the entities waiting to be indexed in two in-memory queues (the resolve queue and the index queue). When XWiki stops, DefaultSolrIndexer#dispose() clears both queues without processing them, so every change saved shortly before the stop is missing from the Solr index: the documents, objects, object properties and attachments of the last saves, and also what a job finishing during the shutdown produced.
The index synchronization only partly repairs it:
- it runs only at startup on an instance with solr.synchronizeAtStartup=true (or when an administrator starts it);
- it compares only the version of the document rows and re-indexes the documents whose version differs, so a lost update of an object, an object property or an attachment whose document row was already indexed is never repaired;
- a lost deletion of an object or an attachment leaves an orphan row in the index (see XWIKI-22949).
In a cluster sharing a remote Solr server, the other members no longer index the changes of the member that stops (XWIKI-25255), so they do not hide this loss any more.
Expected
When XWiki stops, the indexer processes what is already queued before stopping, bounded by a timeout, while the document store and the Solr client are still available (the indexer is disposed with priority 500; the Solr clients and the database store must stay usable until it is done). What is left after the timeout is logged.
Attachments
Issue Links
- relates to
-
XWIKI-22949 Solr index synchronization on startup doesn't remove deleted objects, object properties or attachments
-
- Open
-
-
XWIKI-25255 Every cluster member sends the same index updates to a remote Solr server
-
- Open
-
-
XWIKI-25248 Stop the remote observation channels last when XWiki stops
-
- Open
-