From 755788ecfbfe8c77412c577587c15153b6ff1c6d Mon Sep 17 00:00:00 2001 From: Kresten Krab Thorup Date: Mon, 23 Apr 2012 14:14:12 +0200 Subject: [PATCH] Fix for hanoi store recovery If we're opening a hanoi store configured with smaller nursery size than the default, then we need to make sure that we also open the small levels. Future feature is to actually squash the smaller levels. --- src/hanoi.erl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/hanoi.erl b/src/hanoi.erl index 27c0aaf..de25df9 100644 --- a/src/hanoi.erl +++ b/src/hanoi.erl @@ -240,7 +240,7 @@ open_levels(Dir,Options) -> {Level, NextMax} end, {undefined, 0}, - lists:seq(MaxLevel, ?TOP_LEVEL, -1)), + lists:seq(MaxLevel, min(?TOP_LEVEL, MinLevel), -1)), %% we need to do this much merge work before we can guarantee %% response times ... this is the amount of "in flight" merging