如何使用Rexster Docker镜像和灯泡在TinkerPop / Rextser中创buildgraphics数据库?

我如何创build一个新的数据库? 我正在使用“ https://github.com/konrade/docker-rexster ”中的Rexster Docker镜像来启动并运行一个function正常的Rexster服务器。 它使用以下命令运行:

sudo docker.io run -i -t -P 6cced29c46a3 /bin/bash 

并validation哪个端口分配给Rexster必要的8182像这样:

 sudo docker.io port <container id> 8182 

我有信心服务器正在运行,因为我去url时,与TinkerPop字符的网页

 'http://localhost:49153'. 

但我不能得到在灯泡快速入门部分成功执行的简单例子。 这是我正在尝试执行的简单代码:

 from bulbs.rexster import Graph, Config config = Config('http://localhost:49153/graphs/dantest') g = Graph(config) 

将创build一个neo4j数据库解决我的问题? 如果是的话,那么用来创build它的代码是什么?

灯泡不会为您创buildgraphics – 为此,您必须configurationrexster.xml以创build特定的graphics。

默认的graphics名称是emptygraph所以这应该工作的框…

 >>> from bulbs.rexster import Graph, Config >>> config = Config('http://localhost:49153/graphs/emptygraph') >>> g = Graph(config) 
Interesting Posts