Skip to content

Commit

Permalink
update check condition
Browse files Browse the repository at this point in the history
  • Loading branch information
july2993 committed May 24, 2019
1 parent 8a85643 commit 3f87142
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion pump/storage/storage.go
Original file line number Diff line number Diff line change
Expand Up @@ -554,6 +554,7 @@ func (a *Append) doGCTS(ts int64) {
if stats.LevelTablesCounts[0] >= l0Trigger {
log.Info("wait some time to gc cause too many L0 file", stats.LevelTablesCounts[0])
time.Sleep(5 * time.Second)
continue
}

irange := &util.Range{
Expand All @@ -575,7 +576,9 @@ func (a *Append) doGCTS(ts int64) {
}
}

if !iter.Next() {
iter.Release()

if deleteBatch < 100 {
if batch.Len() > 0 {
err := a.metadata.Write(batch, nil)
if err != nil {
Expand Down

0 comments on commit 3f87142

Please sign in to comment.