diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md index 43084d925..7be173f82 100644 --- a/docs/CHANGELOG.md +++ b/docs/CHANGELOG.md @@ -32,9 +32,9 @@ See also [LTS releases](https://docs.victoriametrics.com/lts-releases/). * FEATURE: [vmbackupmanager](https://docs.victoriametrics.com/vmbackupmanager.html): allow specifying custom backup interval via `-backupInterval` command-line flag. See [this feature request](https://github.com/VictoriaMetrics/VictoriaMetrics/issues/5966). +* BUGFIX: fix incorrect merge of partitions which could lead to losing records for IndexDB. See [this](https://github.com/VictoriaMetrics/VictoriaMetrics/issues/5959) and [this](https://github.com/VictoriaMetrics/VictoriaMetrics/issues/6069) issues. * BUGFIX: [vmbackupmanager](https://docs.victoriametrics.com/vmbackupmanager.html): fix panic when performing a restore from GCS. Previously, filters for GCS objects were not properly set which caused objects to be returned instead of prefixes. - ## [v1.100.0](https://github.com/VictoriaMetrics/VictoriaMetrics/releases/tag/v1.100.0) Released at 2024-04-04 diff --git a/lib/mergeset/table.go b/lib/mergeset/table.go index f22f2406f..b9202f4e5 100644 --- a/lib/mergeset/table.go +++ b/lib/mergeset/table.go @@ -198,7 +198,7 @@ func (riss *rawItemsShards) addIbsToFlush(tb *Table, ibsToFlush []*inmemoryBlock } riss.ibsToFlush = append(riss.ibsToFlush, ibsToFlush...) if len(riss.ibsToFlush) >= maxBlocksPerShard*cgroup.AvailableCPUs() { - ibsToMerge = ibsToFlush + ibsToMerge = riss.ibsToFlush riss.ibsToFlush = nil } riss.ibsToFlushLock.Unlock()