titan icon indicating copy to clipboard operation
titan copied to clipboard

Consider removing blob index deletion marker

Open Connor1996 opened this issue 5 years ago • 2 comments

image As mentioned in the comment, before we use the deletion marker as a workaround for the empty result after merge. But actually, the result shouldn't be empty because it would expose stale versions of the key. Instead, it should output the delete type which provides two profits:

  • reduce code complexity
  • rocksdb compaction can help remove the delete record in the bottommost level instead of keeping the deletion marker forever

As we already make the merge operator support changing value type https://github.com/tikv/rocksdb/blob/6.4.tikv/include/rocksdb/merge_operator.h#L121, seems we can remove the blob index deletion marker.

/cc @tabokie, not sure whether there was any other consideration before. Also, please push https://github.com/facebook/rocksdb/pull/6447 to be merged in upstream

Connor1996 avatar May 26 '20 05:05 Connor1996

@Connor1996 Currently merge operator doesn't support output delete type. I didn't implement it because there are certain complications from upper level: deleted value (in general a non-concrete result) requires a different set of processing logic, which is often seperated from the merge procedure. I'll attend to this once available.

tabokie avatar May 26 '20 07:05 tabokie

So the API support type changes, but the rocksdb implementation is not supported yet. Got it.

Connor1996 avatar May 26 '20 08:05 Connor1996