mirror of
https://gitee.com/milvus-io/milvus.git
synced 2025-12-06 17:18:35 +08:00
fix: Do compressBinlog to fix logID 0 (#34060)
issue: https://github.com/milvus-io/milvus/issues/34059 Do compressBinlog to ensure that reloadFromKV will fill binlogs' logID after datacoord restarts. --------- Signed-off-by: bigsheeper <yihao.dai@zilliz.com>
This commit is contained in:
parent
e0e06fc9e0
commit
fb870d2426
@ -217,29 +217,23 @@ func (kc *Catalog) applyBinlogInfo(segments []*datapb.SegmentInfo, insertLogs, d
|
|||||||
for _, segmentInfo := range segments {
|
for _, segmentInfo := range segments {
|
||||||
if len(segmentInfo.Binlogs) == 0 {
|
if len(segmentInfo.Binlogs) == 0 {
|
||||||
segmentInfo.Binlogs = insertLogs[segmentInfo.ID]
|
segmentInfo.Binlogs = insertLogs[segmentInfo.ID]
|
||||||
} else {
|
}
|
||||||
err = binlog.CompressFieldBinlogs(segmentInfo.Binlogs)
|
if err = binlog.CompressFieldBinlogs(segmentInfo.Binlogs); err != nil {
|
||||||
if err != nil {
|
return err
|
||||||
return err
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if len(segmentInfo.Deltalogs) == 0 {
|
if len(segmentInfo.Deltalogs) == 0 {
|
||||||
segmentInfo.Deltalogs = deltaLogs[segmentInfo.ID]
|
segmentInfo.Deltalogs = deltaLogs[segmentInfo.ID]
|
||||||
} else {
|
}
|
||||||
err = binlog.CompressFieldBinlogs(segmentInfo.Deltalogs)
|
if err = binlog.CompressFieldBinlogs(segmentInfo.Deltalogs); err != nil {
|
||||||
if err != nil {
|
return err
|
||||||
return err
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if len(segmentInfo.Statslogs) == 0 {
|
if len(segmentInfo.Statslogs) == 0 {
|
||||||
segmentInfo.Statslogs = statsLogs[segmentInfo.ID]
|
segmentInfo.Statslogs = statsLogs[segmentInfo.ID]
|
||||||
} else {
|
}
|
||||||
err = binlog.CompressFieldBinlogs(segmentInfo.Statslogs)
|
if err = binlog.CompressFieldBinlogs(segmentInfo.Statslogs); err != nil {
|
||||||
if err != nil {
|
return err
|
||||||
return err
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return nil
|
return nil
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user