Rocksdb state directory should be created before opening the DB
In RocksDBStore.openDB we call
Files.createDirectories(dir.getParentFile().toPath());
return RocksDB.open(options, dir.getAbsolutePath());
We would also add the absolute file path as well to avoid the extra logging.
Reviewers: Matthias J. Sax Guozhang Wang
@@ -158,6 +158,7 @@ public class RocksDBStore implements KeyValueStore<Bytes, byte[]> {
try {
try {
Files.createDirectories(dbDir.getParentFile().toPath());
+ Files.createDirectories(dbDir.getAbsoluteFile().toPath());
db = RocksDB.open(options, dbDir.getAbsolutePath());
} catch (final RocksDBException e) {
throw new ProcessorStateException("Error opening store " + name + " at location " + dbDir.toString(), e);
