rocksdb/java
Siying Dong c757f5b4e3 Java's Get() to directly return for NotFound (#14095)
Summary:
Right now, in Java's Get() calls, the way Get() is treated is inefficient. Status.NotFound is turned into an exception in the JNI layer, and is caught in the same function to turn into not found return. This causes significant overhead in the scenario where most of the queries ending up with not found. For example, in Spark's deduplication query, this exception creation overhead is higher than Get() itself. With the proposed change, if return status is NotFound, we directly return, rather than going through the exception path

Pull Request resolved: https://github.com/facebook/rocksdb/pull/14095

Test Plan: Existing tests should cover all Get() cases, and they are passing.

Reviewed By: jaykorean

Differential Revision: D86797594

Pulled By: cbi42

fbshipit-source-id: 1202d24e46a2358976bb7c8ff38a2fd4783d0f99
2025-11-11 15:58:00 -08:00
..
benchmark/src/main/java/org/rocksdb/benchmark Remove deprecated Options::access_hint_on_compaction_start (#11654) 2024-02-05 13:35:19 -08:00
crossbuild Pass build parallelism flag to Docker builds (#12392) 2024-02-28 12:51:00 -08:00
jmh JNI get_helper code sharing / multiGet() use efficient batch C++ support (#12344) 2024-03-12 12:42:08 -07:00
rocksjni Java's Get() to directly return for NotFound (#14095) 2025-11-11 15:58:00 -08:00
samples/src/main/java Remove compressed block cache (#11117) 2023-01-24 17:09:19 -08:00
src Statistics for successfully resumed compaction output bytes (#14054) 2025-10-17 11:38:20 -07:00
CMakeLists.txt Update window build cmake to download newer snappy version and Java cmake_minimum_required (#13514) 2025-04-02 15:46:02 -07:00
GetPutBenchmarks.md Java API consistency between RocksDB.put() , .merge() and Transaction.put() , .merge() (#11019) 2023-12-11 11:03:17 -08:00
HISTORY-JAVA.md Update JAVA-HISTORY.md for v3.13 2015-08-04 18:12:58 -07:00
jdb_bench.sh Add copyright headers per FB open-source checkup tool. (#5199) 2019-04-18 10:55:01 -07:00
Makefile Add native logger support to RocksJava (#12213) 2024-01-17 17:51:36 -08:00
pmd-rules.xml Java API consistency between RocksDB.put() , .merge() and Transaction.put() , .merge() (#11019) 2023-12-11 11:03:17 -08:00
pom.xml.template Perform java static checks in CI (#11221) 2023-10-17 10:04:35 -07:00
RELEASE.md Add shared library for musl-libc (#3143) 2019-11-26 18:24:09 -08:00
spotbugs-exclude.xml Perform java static checks in CI (#11221) 2023-10-17 10:04:35 -07:00
understanding_options.md New-style blob option bindings, Java option getter and improve/fix option parsing (#8999) 2021-10-19 09:21:52 -07:00