use of com.baidu.hugegraph.backend.store.raft.RaftBackendStoreProvider in project incubator-hugegraph by apache.
the class BackendProviderFactory method open.
public static BackendStoreProvider open(HugeGraphParams params) {
HugeConfig config = params.configuration();
String backend = config.get(CoreOptions.BACKEND).toLowerCase();
String graph = config.get(CoreOptions.STORE);
boolean raftMode = config.get(CoreOptions.RAFT_MODE);
BackendStoreProvider provider = newProvider(config);
if (raftMode) {
LOG.info("Opening backend store '{}' in raft mode for graph '{}'", backend, graph);
provider = new RaftBackendStoreProvider(provider, params);
}
provider.open(graph);
return provider;
}
Aggregations