-
Notifications
You must be signed in to change notification settings - Fork 93
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add compaction order check and data block cache check #195
Conversation
Signed-off-by: Connor1996 <zbk602423539@gmail.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For the table reader change, are all the index iterator being valid when index_iter->key()
is used?
btw CI looks like real failure. |
@@ -2959,10 +2978,10 @@ bool BlockBasedTableIterator<TBlockIter, TValue>::InitDataBlock() { | |||
/*get_context=*/nullptr, &lookup_context_, s, prefetch_buffer_.get(), | |||
/*for_compaction=*/lookup_context_.caller == | |||
TableReaderCaller::kCompaction); | |||
if (!block_iter_.Valid()) { | |||
block_iter_points_to_real_block_ = true; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why reset block_iter_points_to_real_block_
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we invalidate the block iter when corruption detected. If not set block_iter_points_to_real_block_ = true
, upper place will check the status of index iter instead of block iter.
CI is still failing. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
cherry-pick 3.0 and 4.0? |
@yiwu-arbug Not sure if it would be false positive. Let's enable it in master for a while and cherry pick to 4.0 later? |
update rocksdb to include tikv/rocksdb#195 for master Signed-off-by: ti-srebot <ti-srebot@pingcap.com>
* add compaction order check and data block cache check Signed-off-by: Connor1996 <zbk602423539@gmail.com>
Add checks to avoid wrongly mapping block cache populating
get
anditerator
further., for more information of the wrongly mapping block cache, see facebook#7405Add check logic: