facebook / rocksdb

A library that provides an embeddable, persistent key-value store for fast storage.
http://rocksdb.org
GNU General Public License v2.0
28.67k stars 6.33k forks source link

rocksdbjni: ReadOption#setIterateUpperBound does not support DirectSlice #13098

Open lizhanhui opened 2 weeks ago

lizhanhui commented 2 weeks ago

Note: Please use Issues only for bug reports. For questions, discussions, feature requests, etc. post to dev group: https://groups.google.com/forum/#!forum/rocksdb or https://www.facebook.com/groups/rocksdb.dev

Expected behavior

Iterator created with DirectSlice upper bound should work exactly the same way Slice bound.

Actual behavior

Iterator created with DirectSlice is invalid.

Steps to reproduce the behavior

Here is a minimal reproducible code that may verify Slice bound works while DirectSlice fails:

https://github.com/lizhanhui/rocksdb-bug-report/blob/main/src/test/java/lab/rocksdb/RocksDBTest.java

gitlijian commented 1 week ago

hi, @lizhanhui I think this class is implemented in Java. Is there any problem with implementing this class in Java, or are you calling it incorrectly? image