This is a lightweight RocksDB Server based on jetty.
Java client: https://github.com/iamyulong/rocksdb-client-java
- Multiple concurrent databases;
- Simple API interface and client libraries;
- Basic Authentication;
- Batch
put
,get
andremove
operations.
You need to have a Java 8 or above runtime installed.
- Download and unzip the latest binary release from here;
- Update the configuration file at
./conf/server.json
; - Start up the server:
./bin/startup.sh
.
Once boot up, you can check if it's working via http://localhost:8516.
-
Copy the following config to
/etc/init.d/rocksdb-server
, after replacingSERVER_ROOT
with a real path:#!/bin/bash ### BEGIN INIT INFO # Provides: rocksdb-server # Required-Start: $network # Required-Stop: $network # Default-Start: 2 3 4 5 # Default-Stop: 0 1 6 # Short-Description: start/stop rocksdb-server ### END INIT INFO SERVER_ROOT=/path/to/rocksdb/server case $1 in start) /bin/bash $SERVER_ROOT/bin/startup.sh ;; stop) /bin/bash $SERVER_ROOT/bin/shutdown.sh ;; restart) /bin/bash $SERVER_ROOT/bin/restart.sh ;; esac exit 0
-
Update the permissions and enable service:
chmod 755 /etc/init.d/rocksdb-server update-rc.d rocksdb-server defaults
-
Now, you can start/stop/restart your server via the following commands:
service rocksdb-server start service rocksdb-server stop service rocksdb-server restart
git clone https://github.com/iamyulong/rocksdb-server
cd rocksdb-server
mvn clean install