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-4528 remove PushRevWithHistory #7400

Merged
merged 1 commit into from
Feb 26, 2025
Merged

Conversation

torcolvin
Copy link
Collaborator

@torcolvin torcolvin commented Feb 26, 2025

CBG-4528 remove PushRevWithHistory/PushUnsolicitedRev

This was used to push unsolicited rev and check failure of the message. Instead of wrapping this in blip code, send the message separately and check the actual error.

This is also an intermediate commit for full CBG-4528 but allows removing a large code pathway. The problem with PushRevWithHistory was that it called upsertDoc so an outgoing pull replication would see the changes. So this had to avoid being called at the same time as a pull replication to avoid a data race.

Additionally, the error TestBlipDeltaSyncPush was wrapped as followed fmt.Errorf("error %s %s from revResponse: %s", revResponse.Properties["Error-Domain"], revResponse.Properties["Error-Code"], rspBody) so the assertion was indirect at best since the verfication is on deltaSrc.

The test doesn't actually set the correct body for the delta but that is OK since the assertion is set on `deltaRev

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

This was used to push unsolicited rev and check failure of the message.
Instead of wrapping this in blip code, send the message separately and
check the actual error.
@torcolvin torcolvin merged commit cfcc0fe into main Feb 26, 2025
44 checks passed
@torcolvin torcolvin deleted the CBG-4528-remove-unsolicited-rev branch February 26, 2025 15:40
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.

2 participants