-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
enhance: Periodically synchronize segments to datanode watcher #33420
enhance: Periodically synchronize segments to datanode watcher #33420
Conversation
@xiaocai2333 ut workflow job failed, comment |
@xiaocai2333 E2e jenkins job failed, comment |
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #33420 +/- ##
==========================================
- Coverage 82.21% 82.19% -0.02%
==========================================
Files 1012 1013 +1
Lines 129202 129387 +185
==========================================
+ Hits 106223 106353 +130
- Misses 19001 19060 +59
+ Partials 3978 3974 -4
|
/run-cpu-e2e |
@xiaocai2333 E2e jenkins job failed, comment |
7f27783
to
21c2b45
Compare
@xiaocai2333 ut workflow job failed, comment |
Signed-off-by: Cai Zhang <cai.zhang@zilliz.com>
Signed-off-by: Cai Zhang <cai.zhang@zilliz.com>
Signed-off-by: Cai Zhang <cai.zhang@zilliz.com>
Signed-off-by: Cai Zhang <cai.zhang@zilliz.com>
Signed-off-by: Cai Zhang <cai.zhang@zilliz.com>
0fa524c
to
5ebd62a
Compare
log := log.With(zap.Int64("collectionID", collectionID), zap.Int64("partitionID", partitionID), | ||
zap.String("channelName", channelName), zap.Int64("nodeID", nodeID)) | ||
segments := sss.meta.SelectSegments(WithCollection(collectionID), WithChannel(channelName), SegmentFilterFunc(func(info *SegmentInfo) bool { | ||
return info.GetPartitionID() == partitionID |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add a new WithPartition filter
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
no need to do this.
} | ||
|
||
for _, seg := range segments { | ||
compactTo := int64(-1) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No need to related to compaction any more.
zap.Error(err)) | ||
continue | ||
} | ||
for _, channelName := range collInfo.VChannelNames { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe we can execute concurrently at the channel level?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I thinks it's no necessary. I already add the concurrently for load pk in datanode.
Signed-off-by: Cai Zhang <cai.zhang@zilliz.com>
Signed-off-by: Cai Zhang <cai.zhang@zilliz.com>
@xiaocai2333 ut workflow job failed, comment |
rerun ut |
@@ -285,3 +248,56 @@ func (c *metaCacheImpl) rangeWithFilter(fn func(id int64, info *SegmentInfo), fi | |||
} | |||
} | |||
} | |||
|
|||
func (c *metaCacheImpl) DetectMissingSegments(segments map[int64]struct{}) []int64 { | |||
c.mu.Lock() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
RLock?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yeah, oversight.
Signed-off-by: Cai Zhang <cai.zhang@zilliz.com>
select { | ||
case <-sss.quit: | ||
log.Info("sync segments scheduler quit") | ||
ticker.Stop() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
remove this
/approve |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: czs007, xiaocai2333 The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
…s-io#33420) issue: milvus-io#32809 --------- Signed-off-by: Cai Zhang <cai.zhang@zilliz.com>
…s-io#33420) issue: milvus-io#32809 --------- Signed-off-by: Cai Zhang <cai.zhang@zilliz.com>
…s-io#33420) issue: milvus-io#32809 --------- Signed-off-by: Cai Zhang <cai.zhang@zilliz.com>
…s-io#33420) issue: milvus-io#32809 --------- Signed-off-by: Cai Zhang <cai.zhang@zilliz.com>
…watcher (#33420) (#34186) This PR primary picks up the SyncSegments functionality, including the following commits: - main functionality: #33420 - related fixes: - #33664 - #33829 - #34056 - #34156 issue: #32809 master pr: #33420, #33664, #33829, #34056, #34156 Signed-off-by: Cai Zhang <cai.zhang@zilliz.com>
…s-io#33420) issue: milvus-io#32809 --------- Signed-off-by: Cai Zhang <cai.zhang@zilliz.com>
issue: #32809