Search in sources :

Example 1 with HugeGraphAuthProxy

use of com.baidu.hugegraph.auth.HugeGraphAuthProxy in project incubator-hugegraph by apache.

the class GraphManager method loadGraph.

private void loadGraph(String name, String path) {
    final Graph graph = GraphFactory.open(path);
    this.graphs.put(name, graph);
    HugeConfig config = (HugeConfig) graph.configuration();
    config.file(path);
    LOG.info("Graph '{}' was successfully configured via '{}'", name, path);
    if (this.requireAuthentication() && !(graph instanceof HugeGraphAuthProxy)) {
        LOG.warn("You may need to support access control for '{}' with {}", path, HugeFactoryAuthProxy.GRAPH_FACTORY);
    }
}
Also used : Graph(org.apache.tinkerpop.gremlin.structure.Graph) HugeGraph(com.baidu.hugegraph.HugeGraph) HugeConfig(com.baidu.hugegraph.config.HugeConfig) HugeGraphAuthProxy(com.baidu.hugegraph.auth.HugeGraphAuthProxy)

Aggregations

HugeGraph (com.baidu.hugegraph.HugeGraph)1 HugeGraphAuthProxy (com.baidu.hugegraph.auth.HugeGraphAuthProxy)1 HugeConfig (com.baidu.hugegraph.config.HugeConfig)1 Graph (org.apache.tinkerpop.gremlin.structure.Graph)1