PokIsemaine opened a new issue, #2326: URL: https://github.com/apache/kvrocks/issues/2326
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/kvrocks/issues) and found no similar issues. ### Version unstable:commit 9b1ebcd ### Minimal reproduce step ``` 127.0.0.1:6666> MULTI OK 127.0.0.1:6666> SET key 123 QUEUED 127.0.0.1:6666> FLUSHDB QUEUED 127.0.0.1:6666> EXEC 1) OK 2) (error) ERR Not implemented: DeleteRange unsupported in WriteBatchWithIndex ``` ### What did you expect to see? Redis: ``` # redis-cli 127.0.0.1:6379> MULTI OK 127.0.0.1:6379(TX)> SET key 123 QUEUED 127.0.0.1:6379(TX)> FLUSHDB QUEUED 127.0.0.1:6379(TX)> EXEC 1) OK 2) OK 127.0.0.1:6379> GET key (nil) 127.0.0.1:6379> ``` ### What did you see instead? ERR Not implemented: DeleteRange unsupported in WriteBatchWithIndex rocksdb ref: https://github.com/facebook/rocksdb/blob/c72ee4531b288bf08b9414155fafb86cc4378fb4/include/rocksdb/utilities/write_batch_with_index.h#L165 ### Anything Else? I discovered this issue while trying to solve https://github.com/apache/kvrocks/issues/2310. One of my solutions in issue-2310 was to imitate the current transaction implementation and use WriteBatchWithIndex > issue-2310 > 2. Get WriteBatchWithIndex in GetWriteBatchBase, but I found that WriteBatchWithIndex cannot support all operations of WriteBatch, such as DeleteRange. Even after using WriteBatchWithIndex::GetWriteBatch after DeleteRange, we cannot index the effect of DeleteRange in Batch through GetFromBatchAndDB. ### Are you willing to submit a PR? - [ ] I'm willing to submit a PR! -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
