Benjamin Habegger created OAK-12163:
---------------------------------------
Summary: Allow generating indices on multiple targets to ease
migration
Key: OAK-12163
URL: https://issues.apache.org/jira/browse/OAK-12163
Project: Jackrabbit Oak
Issue Type: Improvement
Reporter: Benjamin Habegger
Currently, OAK provides multiple index types among which lucene and elastic.
Furthermore, the an new implementation of the lucene indices is in the workings
(see OAK-12089). For situations where a full reindexing may take time and/or we
want to be able to switch back to a previous version of an index in a
transition phase, having a mechanism to be able to maintain up to date multiple
index types for the same index definition is very worthwhile.
This ticket proposes to implement this in the following way.
Deprecate but continue support the *type* of an index definition.
Introduce 2 new properties to the index definition (whose values are the same
as those the existing type field can take):
* activeTarget - the index storage target used at query time
* storedTaregts - the list of storage targets to we written to at index time
At query time the index target (lucene, elastic, lucene9, etc.) to be used is
the one specified in activeTarget (with a fallback on type if activeTarget is
absent).
At index time all the storedTargets are written to (or to the one specified in
type).
A "catchup" mechanism would allow to add a new storedTarget and allow a new
target to be fully built without disturbing the existing running index and it's
updates.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)