“Permanent Exception” connecting Titan 0.4.0 to Datastax AMI

依然范特西╮ 提交于 2019-12-08 04:26:10

问题


I'm new in the Titan realm so I'll keep this question as simple as possible.

Using the instructions provided here, I am able to successfully connect 1 linux node running Titan 0.3.2 to the Datastax/Cassandra instance as a backend.

I then downloaded Titan 0.4.0 and attempted the same, but receive a backend exception. For good measure, I changed the keyspace to in my .properties file to "titan4", which I then see reflected in the Cassandra backend.

However, despite successfully seeing the "titan4" keyspace created in Cassandra, I get a rather useless exception and stack trace. I'm a hobbyist, and very new at all technologies involved. Any help is greatly appreciated.

gremlin> g = TitanFactory.open('conf/titan-t2.properties')
Permanent exception during backend operation
Display stack trace? 

_

com.thinkaurelius.titan.core.TitanException: Permanent exception during backend operation
        at com.thinkaurelius.titan.diskstorage.util.BackendOperation.execute(BackendOperation.java:32)
        at com.thinkaurelius.titan.diskstorage.Backend.initialize(Backend.java:252)
        at com.thinkaurelius.titan.graphdb.configuration.GraphDatabaseConfiguration.getBackend(GraphDatabaseConfiguration.java:683)
        at com.thinkaurelius.titan.graphdb.database.StandardTitanGraph.<init>(StandardTitanGraph.java:72)
        at com.thinkaurelius.titan.core.TitanFactory.open(TitanFactory.java:40)
        at com.thinkaurelius.titan.core.TitanFactory.open(TitanFactory.java:29)
        at com.thinkaurelius.titan.core.TitanFactory$open.call(Unknown Source)
        at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:42)
        at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:108)
        at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:116)
        at groovysh_evaluate.run(groovysh_evaluate:56)
        at groovysh_evaluate$run.call(Unknown Source)
        at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:42)
        at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:108)
        at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:112)
        at org.codehaus.groovy.tools.shell.Interpreter.evaluate(Interpreter.groovy:67)
        at org.codehaus.groovy.tools.shell.Interpreter$evaluate.call(Unknown Source)
        at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:42)
        at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:108)
        at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:116)
        at org.codehaus.groovy.tools.shell.Groovysh.execute(Groovysh.groovy:152)
        at org.codehaus.groovy.tools.shell.Shell.leftShift(Shell.groovy:114)
        at org.codehaus.groovy.tools.shell.Shell$leftShift$0.call(Unknown Source)
        at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:42)
        at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:108)
        at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:116)
        at org.codehaus.groovy.tools.shell.ShellRunner.work(ShellRunner.groovy:88)
        at org.codehaus.groovy.tools.shell.InteractiveShellRunner.super$2$work(InteractiveShellRunner.groovy)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:606)
        at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:90)
        at groovy.lang.MetaMethod.doMethodInvoke(MetaMethod.java:233)
        at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:1079)
        at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.invokeMethodOnSuperN(ScriptBytecodeAdapter.java:128)
        at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.invokeMethodOnSuper0(ScriptBytecodeAdapter.java:148)
        at org.codehaus.groovy.tools.shell.InteractiveShellRunner.work(InteractiveShellRunner.groovy:100)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:606)
        at org.codehaus.groovy.runtime.callsite.PogoMetaMethodSite$PogoCachedMethodSiteNoUnwrapNoCoerce.invoke(PogoMetaMethodSite.java:272)
        at org.codehaus.groovy.runtime.callsite.PogoMetaMethodSite.callCurrent(PogoMetaMethodSite.java:52)
        at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallCurrent(CallSiteArray.java:46)
        at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:133)
        at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:137)
        at org.codehaus.groovy.tools.shell.ShellRunner.run(ShellRunner.groovy:57)
        at org.codehaus.groovy.tools.shell.InteractiveShellRunner.super$2$run(InteractiveShellRunner.groovy)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:606)
        at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:90)
        at groovy.lang.MetaMethod.doMethodInvoke(MetaMethod.java:233)
        at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:1079)
        at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.invokeMethodOnSuperN(ScriptBytecodeAdapter.java:128)
        at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.invokeMethodOnSuper0(ScriptBytecodeAdapter.java:148)
        at org.codehaus.groovy.tools.shell.InteractiveShellRunner.run(InteractiveShellRunner.groovy:66)
        at com.thinkaurelius.titan.tinkerpop.gremlin.Console.<init>(Console.java:57)
        at com.thinkaurelius.titan.tinkerpop.gremlin.Console.<init>(Console.java:70)
        at com.thinkaurelius.titan.tinkerpop.gremlin.Console.main(Console.java:96)
    Caused by: com.thinkaurelius.titan.diskstorage.PermanentStorageException: Permanent failure in storage backend
        at com.thinkaurelius.titan.diskstorage.cassandra.thrift.CassandraThriftStoreManager.setConfigurationProperty(CassandraThriftStoreManager.java:479)
        at com.thinkaurelius.titan.diskstorage.Backend$2.call(Backend.java:257)
        at com.thinkaurelius.titan.diskstorage.Backend$2.call(Backend.java:252)
        at com.thinkaurelius.titan.diskstorage.util.BackendOperation.execute(BackendOperation.java:29)
        ... 61 more
    Caused by: java.lang.NullPointerException
        at org.apache.cassandra.utils.ByteBufferUtil.bytes(ByteBufferUtil.java:243)
        at org.apache.cassandra.cql.jdbc.JdbcUTF8.decompose(JdbcUTF8.java:98)
        at org.apache.cassandra.db.marshal.UTF8Type.decompose(UTF8Type.java:39)
        at org.apache.cassandra.db.marshal.UTF8Type.fromString(UTF8Type.java:61)
        at com.thinkaurelius.titan.diskstorage.cassandra.thrift.CassandraThriftStoreManager.setConfigurationProperty(CassandraThriftStoreManager.java:470)

EDIT:

Logging into Datastax image:

And Java version (I had to manually upgrade to 1.7 from 1.6 on the Linux AMI or Gremlin wouldn't run)


回答1:


I have been able to use Titan against DSE 4.6 which runs C* 2.0.11

Here's the latest testing from the Aurelius team -- http://s3.thinkaurelius.com/docs/titan/0.5.4/version-compat.html#d0e15023

Here are the steps I followed on my DSE box:

Pull and extract the binaries

wget http://s3.thinkaurelius.com/downloads/titan/titan-all-0.4.4.zip
unzip titan-all-0.4.4.zip 



cd titan-all-0.4.4
bin/gremlin.sh

Inside the Gremlin shell load the db:

g = TitanFactory.open('conf/titan-cassandra-es.properties')
GraphOfTheGodsFactory.load(g)

Some quick tests:

saturn = g.V('name','saturn').next()
saturn.getProperty('name')
saturn.map()
saturn.in('father').in('father').name

g.E.has('place',WITHIN,Geoshape.circle(37.97,23.72,50))



回答2:


I see in your Datastax AMI machine you have Cassandra 2, while Titan has a tested compatibility with a lower version of Cassandra (1.2).

Try to install Cassandra 1.2 and try again.

EDIT:

Since Titan 0.50 both Cassandra 1.2 and 2.0 are supported as stated on the compatibility page.



来源:https://stackoverflow.com/questions/20064396/permanent-exception-connecting-titan-0-4-0-to-datastax-ami

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!