-
Notifications
You must be signed in to change notification settings - Fork 72
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
CBL-6597: The proposeChange not include remote revision id for the up… (
#2200) * CBL-6597: The proposeChange not include remote revision id for the updated doc when using version vector This occurs because as we produce originalRecord from VectorRecord, we overlooked the effect of kSync flag. This happens when the copy constructor of VectorRecord is called. We do the following to fix the problem. 1. As we clear flag kSynced in VectorRecord, we make a note with _wasSynced, in VectorRecord. In particular, it applies to the source VectorRecord. 2. The copy constructor will use the originalRecord produced by the source VectorRecord. As we do it, we put back (restore) kSynced in the originalRecord if _wasSynced is set. 3. As we construct VectorRecord from the originalRecord of the source VectorRecord, we (already) pass DocumentFlags from the originalRecord to the target VectorRecord, which now includes kSynced. And, thus, it circles back to the state when the document is loaded from the KeyStore when kSynced is set.
- Loading branch information
1 parent
e6ca3aa
commit 89151de
Showing
3 changed files
with
47 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters