-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow reindexing a Storage #24
Comments
Alternatives:
|
Depending on the goals, following solutions are viable:
partial global order gives best results vs. implementation cost, but no strong guarantees. The partial global order could be "upgraded" to TrueTime though, by storing two timestamps. As long as a single writer is still used (no replication in place), this would still provide a strong consistency with a monotonic clock in the system and write-timestamp given by the writer. |
With #80 a global order can be established via the monotonic clock stamp and/or the sequence number in the document header. |
This is a very expensive operation, as it involves a full database scan, but it can help when indexes get broken and would technically allow for rewriting storage partitions.
Edit: This is not easily possible without completely losing original global document order, since the global version number needs either to be stored in the document record itself (which means writing the index before the document), OR assume that the documents haven't changed in amount and order, so going through the existing index and keeping that order.
An midway alternative would be to just guarantee a chronological order and reindex on commit timestamp (which could still be unrelated to actuall document creation/event occurence order).
The text was updated successfully, but these errors were encountered: