首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >将Rexster配置为使用Titan

将Rexster配置为使用Titan
EN

Stack Overflow用户
提问于 2014-09-15 09:27:59
回答 1查看 829关注 0票数 0

我正在尝试通过修改Rexster中的rexster.xml文件来配置Rexster来使用泰坦。但当我跑

代码语言:javascript
复制
  http ://localhost:8182/graphs/mygraph 

在我的浏览器中,我收到一条消息:

{“消息”:“找不到图迷图”}。

这是我修改的rexster.xml文件的一部分:

代码语言:javascript
复制
    <graph>
    <graph-name>mygraph</graph-name>
    <graph-type>com.thinkaurelius.titan.tinkerpop.rexster.TitanGraphConfiguration</graph-type>
        <graph-location>C:/titan-server-jre6-0.4.4/bin/mygraph</graph-location>
          <graph-read-only>false</graph-read-only>
              <properties>
                    <storage.backend>local</storage.backend>
                    <buffer-size>100</buffer-size>
              </properties>
              <extensions>
                <allows>
                  <allow>tp:gremlin</allow>
                </allows>
              </extensions>
    </graph>

我将Titans lib文件夹中的所有jar文件添加到config/ext/titan下的Rexster中,并使用gremlin shell i Titan在Titan中创建了一个图形:

代码语言:javascript
复制
    g = TitanFactory.open('mygraph');
    g.createKeyIndex('name', Vertex.class);
    v = g.addVertex(null);
    v.setProperty('name','x');
    v.setProperty('type','person');
    v.setProperty('age',20);
    v1 = g.addVertex(null);
    v1.setProperty('name','y');

    v1.setProperty('type','person');

    v1.setProperty('age',22);
    e = g.addEdge(null, v, v1, 'knows');
    e1 = g.addEdge(null, v1, v, 'knows');
    g.shutdown();

我遗漏了什么?

更新

我把来自泰坦的jar文件放在rexster中的错误目录中,现在这些jar文件在rexster中的位置是对的。但是,当我现在运行rexster服务器时,我得到了以下输出:

代码语言:javascript
复制
    [INFO] Application - .:Welcome to Rexster:.
    [INFO] RexsterProperties - Using [C:\rexster-server-2.5.0\config\rexster.xml] as
    configuration source. 
    [INFO] Application - Rexster is watching [C:\rexster-server-2.5.0\config\rexster
    .xml] for change.
    Exception in thread "main" java.lang.AbstractMethodError: com.thinkaurelius.tita 
    n.tinkerpop.rexster.TitanGraphConfiguration.configureGraphInstance(Lcom/tinkerpo
    p/rexster/config/GraphConfigurationContext;)Lcom/tinkerpop/blueprints/Graph;
    at com.tinkerpop.rexster.config.GraphConfigurationContainer.getGraphFrom
    Configuration(GraphConfigurationContainer.java:124)
    at com.tinkerpop.rexster.config.GraphConfigurationContainer.<init>(Graph 
    ConfigurationContainer.java:54)
    at com.tinkerpop.rexster.server.XmlRexsterApplication.reconfigure(XmlRex
    sterApplication.java:99)
    at com.tinkerpop.rexster.server.XmlRexsterApplication.<init>(XmlRexsterA
    pplication.java:47)
    at com.tinkerpop.rexster.Application.<init>(Application.java:97)
    at com.tinkerpop.rexster.Application.main(Application.java:189)

我怎么解决这个问题?

EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2014-09-15 12:21:07

在我使用2.5.0版本之前,通过更改rexster服务器的版本解决了问题。我现在使用的版本2.4.0和版本0.4.4的土卫六。

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/25844805

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档