Skip to content

Commit

Permalink
fix when no L0 files
Browse files Browse the repository at this point in the history
  • Loading branch information
july2993 committed May 24, 2019
1 parent 3f87142 commit 25510d6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pump/storage/storage.go
Original file line number Diff line number Diff line change
Expand Up @@ -551,7 +551,7 @@ func (a *Append) doGCTS(ts int64) {
time.Sleep(5 * time.Second)
continue
}
if stats.LevelTablesCounts[0] >= l0Trigger {
if len(stats.LevelTablesCounts) > 0 && 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
Expand Down

0 comments on commit 25510d6

Please sign in to comment.