pal*_*lom 0 tinkerpop gremlin-server janusgraph
你能告诉我 - 是否可以在 Gremlin 服务器上使用 OGM FERMA 框架(TinkerPop 3.2.6,后端有 JanusGraphDB)?
现在我使用 gremlin 客户端以这种方式向 G-server 发送查询:
GryoMapper mapper = GryoMapper.build().addRegistry(JanusGraphIoRegistry.getInstance()).create();
MessageSerializer serializer = new GryoMessageSerializerV1d0(GryoMapper.build().addRegistry(JanusGraphIoRegistry.getInstance()));
/* Create gremlin cluster... */
Cluster cluster = Cluster.build("123.22.22.111").port(8182).serializer(serializer).create();
Client client = cluster.connect();
ResultSet res = client.submit("g.V().label()");
Run Code Online (Sandbox Code Playgroud)
...因此我不知道如何直接获得图形实例(如在 ferma 教程中):
FramedGraph fg = new DelegatingFramedGraph(graph, true, types);
Run Code Online (Sandbox Code Playgroud)
... 使用遍历来获取 ferma 注释类的实例。
Ferma 旨在与启用 TinkerPop 的嵌入式Graph
实例一起使用。因此,它不适用于 Gremlin 服务器中托管的图形或远程图形提供程序(如 DSE Graph、CosmosDB、Neptune 等)。
归档时间: |
|
查看次数: |
545 次 |
最近记录: |