我这样启动我的 Gremlin NEO4J
./gremlin-server.sh conf/gremlin-server-neo4j.yaml
我已经安装了 OrientDB 社区版,它似乎是通过 IP:2480/studio/index.htm 工作的文件
现在我正在尝试将我的 Gremlin 服务器连接到 Orient DB,但我找不到任何方法来实现它
连接 Gremlin 服务器的 Python 代码
from gremlin_python.driver import client as driver
# Constants for connections to gremlin
GREMLIN_VAR = 'g'
GREMLIN_URL = 'ws://localhost:8182/gremlin'
client = driver.Client(GREMLIN_URL, GREMLIN_VAR)
我发现但没有帮助的内容
- V3 doc但他们使用的是 Java 而不是 Python
- orientdb-server-config.xml但我需要一个用于 python 的 yaml 文件
- gremlin-server.sh -i org.apache.tinkerpop orientdb-gremlin 3.3.1 抛出错误“[ Unresolved 依赖性:org.apache.tinkerpop#orientdb-gremlin;3.3.1:没有找到]'
- 'orientdb-community-importers-2.2.31/bin' 执行了一个名为 'gremlin.sh' 的文件,但我无法执行类似 g = graph.traversal() 的操作
- 尝试了“./gremlin-server.sh -i com.orientechnologies orientdb-gremlin 2.2.31”,它安装了一些东西,但我不知道如何继续。
最佳答案
据我了解,您使用的是非常旧版本的 orientdb
配置,在最新版本中使用 orientdb-gremlin 3.0.2
他们将 gremlin 嵌入了 orientdb对于下载依赖项,请使用此 ./gremlin-server.sh -i com.orientechnologies orientdb-gremlin 3.0.2
根据来自 OP 的更多信息,添加
gremlin.graph=org.apache.tinkerpop.gremlin.orientdb.OrientFactory
orient-url=plocal:txt/GremlinServer
orient-user=admin
orient-pass=admin
希望对你有帮助
谢谢
关于python-3.x - Gremlin 服务器连接到 Orient DB,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/49646876/