Skip to content
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

CBG-3736: delta sync for cv #7141

Open
wants to merge 4 commits into
base: release/anemone
Choose a base branch
from
Open

CBG-3736: delta sync for cv #7141

wants to merge 4 commits into from

Conversation

gregns1
Copy link
Contributor

@gregns1 gregns1 commented Oct 2, 2024

CBG-3736

  • Store CV (In CBL format) on the DocumentDelta (this needs to be stored alongside the ToRevID on the delta for future backwards compatibility reasons)
  • DocumentDelta needs now also stores history in CBL string format
  • When subprotocol version is below v4 and delta sync is requested, fall back to sending full revision
  • GetDelta: fromRevision switch the fetch from rev cache for this revision from using revID to CV, If delta is found on fromRevision we now check if this delta correlates to the top the CV we want the delta for, toRevision: switch the fetch from rev cache to use CV rather than revID
  • UpdateDelta: has a CV version entitled UpdateDeltaCV which uses the CV code path to update a delata on revcache
  • newRevCacheDelta: grabs HLV history off documentRevision and store in onto RevisionDelta for ease of sending to CBL inside sendDelta function
  • processRev: Switch to get by CV from revcache for deltaSrcRev

Pre-review checklist

  • Removed debug logging (fmt.Print, log.Print, ...)
  • Logging sensitive data? Make sure it's tagged (e.g. base.UD(docID), base.MD(dbName))
  • Updated relevant information in the API specifications (such as endpoint descriptions, schemas, ...) in docs/api

Integration Tests

@gregns1 gregns1 requested a review from bbrks October 2, 2024 14:04
@adamcfraser adamcfraser assigned adamcfraser and unassigned bbrks Oct 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants