Repository navigation
account for deferred points in proxies - #8477
Conversation
| "proxied point deletes should have newer version than point in segment {} < {:?}, point id: {}", | ||
| versions.operation_version, | ||
| optimized_segment.point_version(point_id), | ||
| point_id, |
There was a problem hiding this comment.
this not stricitly related to this PR, but I found the original issue while debugging this assertion
📝 WalkthroughWalkthroughThe pull request removes the Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Possibly related PRs
Suggested reviewers
🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment Tip CodeRabbit can approve the review once all CodeRabbit's comments are resolved.Enable the |
There was a problem hiding this comment.
🧹 Nitpick comments (1)
lib/collection/src/shards/local_shard/mod.rs (1)
982-987: Stale documentation references removed parameter.The doc comment at lines 984-986 still describes the
appendable_onlyparameter behavior, but this parameter was removed from the function signature. The documentation should be updated to reflect that the method now always iterates over all segments.📝 Suggested doc comment update
// Perform an operation using the shards segments. // This doesn't lock the SegmentHolder during the operation. - // The function also allows to specify which type of segments to iterate over. - // `appendable_only` iterates over both non-appendable and appendable segments if `false` - // and over appendable segments only if `true`. + // The function iterates over all segments (both appendable and non-appendable). fn do_with_segments<R, F>(&self, mut f: F) -> AbortOnDropHandle<R>🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@lib/collection/src/shards/local_shard/mod.rs` around lines 982 - 987, The doc comment for the method do_with_segments still mentions the removed appendable_only parameter; update the comment to remove any mention of appendable_only and clarify that do_with_segments<R, F>(&self, mut f: F) -> AbortOnDropHandle<R> iterates over all segments (both appendable and non-appendable) and does not lock the SegmentHolder during the operation; keep the rest of the behavior description (e.g., that it performs an operation using the shard's segments and returns an AbortOnDropHandle) consistent with the current signature.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Nitpick comments:
In `@lib/collection/src/shards/local_shard/mod.rs`:
- Around line 982-987: The doc comment for the method do_with_segments still
mentions the removed appendable_only parameter; update the comment to remove any
mention of appendable_only and clarify that do_with_segments<R, F>(&self, mut f:
F) -> AbortOnDropHandle<R> iterates over all segments (both appendable and
non-appendable) and does not lock the SegmentHolder during the operation; keep
the rest of the behavior description (e.g., that it performs an operation using
the shard's segments and returns an AbortOnDropHandle) consistent with the
current signature.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: 831cfbb3-a5c4-4640-bbaa-699326365a36
📒 Files selected for processing (3)
lib/collection/src/shards/local_shard/mod.rslib/shard/src/optimize.rslib/shard/src/proxy_segment/segment_entry.rs
Previous PR incorrectly assumed that deferred points can only exist in appendable segment.
But ProxySegment is non-appendable and it can contain appendable segment with deferred points.