Does rocksdbjava api library contain the rocksdb database itself

365 Views Asked by At

I am very new to rockdb and will be using the rocksdb in my application as a lookup service. Does the rockDBjava library api provided contain the database itself, I mean is it not necessary to install rocksDB database separately.

I tried running the code using library and see some files created in the db path I mentioned in code, so not sure how exactly it works and if I need to install DB separately or if the library stores data in the directory and it itself acts as database?

1

There are 1 best solutions below

0
On

No, you should not need to install RocksDB separately if you already have RocksJava working. They're not very clear on stating that, but if you look at the wiki in their Git repo you'll find this:

RocksJava is structured in 3 layers:

  1. The Java classes within the org.rocksdb package which form the RocksJava API. Java users only directly interact with this layer.

  2. JNI code written in C++ that provides the link between the Java API and RocksDB.

  3. RocksDB itself written in C++ and compiled into a native library which is used by the JNI layer.

That third point is basically their way of saying that RocksDB itself is one of the layers of RocksJava.