Stop Iterator re-use
The IMM iterator should not be reused, as it has already been filtered for a query. so if reused for a different query incorrect and unexpected results may occur. This reuse had been stopped by a previous commit, and this cleans up subsequently unused code.
This commit is contained in:
parent
d21d18dd82
commit
5312806592
1 changed files with 0 additions and 9 deletions
|
@ -1273,15 +1273,6 @@ keyfolder({[{IMMKey, IMMVal}|NxIMMiterator], SSTiterator},
|
||||||
{SegmentList, MaxKeys}) ->
|
{SegmentList, MaxKeys}) ->
|
||||||
{StartKey, EndKey} = KeyRange,
|
{StartKey, EndKey} = KeyRange,
|
||||||
case {IMMKey < StartKey, leveled_codec:endkey_passed(EndKey, IMMKey)} of
|
case {IMMKey < StartKey, leveled_codec:endkey_passed(EndKey, IMMKey)} of
|
||||||
{true, _} ->
|
|
||||||
|
|
||||||
% Normally everything is pre-filterd, but the IMM iterator can
|
|
||||||
% be re-used and so may be behind the StartKey if the StartKey has
|
|
||||||
% advanced from the previous use
|
|
||||||
keyfolder({NxIMMiterator, SSTiterator},
|
|
||||||
KeyRange,
|
|
||||||
{AccFun, Acc},
|
|
||||||
{SegmentList, MaxKeys});
|
|
||||||
{false, true} ->
|
{false, true} ->
|
||||||
% There are no more keys in-range in the in-memory
|
% There are no more keys in-range in the in-memory
|
||||||
% iterator, so take action as if this iterator is empty
|
% iterator, so take action as if this iterator is empty
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue