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-4321: store skipped sequences as single entries below a certain threshold #7173

Merged
merged 3 commits into from
Nov 5, 2024

Conversation

gregns1
Copy link
Contributor

@gregns1 gregns1 commented Oct 29, 2024

CBG-4321

  • Define a new threshold for what skipped seqs need to meet to be stored as a range on the skipped list
  • If below this threshold we will push skipped entries as single entries
  • Changes to tests for this change

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

if numSeqs > MinSequencesForRange {
c.skippedSeqs.PushSkippedSequenceEntry(NewSkippedSequenceRangeEntry(startSeq, endSeq))
} else {
for i := startSeq; i <= endSeq; i++ {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is going to result in a separate lock acquisition for each sequence in the range. Perhaps we want a PushSkippedSequenceEntries(startSeq, endSeq) option on SkippedSequenceSlice that gets the lock once? That would also let us append the set of entries to the list in a single append operation, if that turns out to be more efficient.

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