private Env env;
private String directory;
public LMDBDataInterfaceFactory(CachesManager cachesManager, MemoryManager memoryManager, String directory) {
super(cachesManager, memoryManager);
env = new Env();
env.setMaxDbs(100);
env.setMapSize(200 * 1024 * 1024); //needs to be quite high, otherwise we get EINVAL or MDB_MAP_FULL errors
File directoryAsFile = new File(directory);
if (directoryAsFile.isFile()) {
throw new RuntimeException("Path " + directoryAsFile.getAbsolutePath() + " is a file! Expected a directory...");