Connecting remotely to Titan without Rexter

532 views
Skip to first unread message

Richard Kuiper

unread,
Sep 13, 2013, 8:41:25 AM9/13/13
to aureliu...@googlegroups.com
Hi

I am getting rather confused and would love some clarity.

We are running Titan/Rexter running on a server with cassandra as it's backend running on a different server. So far I have been using gremlin to connect while I attempt to figure everything out.

Titan/Rexter: 10.0.0.5
Cassandra: 10.0.0.6

conf=new BaseConfiguration();
conf.setProperty('storage.backend','cassandra');
conf.setProperty('storage.hostname','10.0.0.6');
g=TitanFactory.open(conf);

I could not connect using 10.0.0.5 and I could never understand why. I always had to use the ip address of cassandra. From what I can gather now, when I call TitanFactory.open(conf) I am actually creating a new instance of Titan on my local machine that is using 10.0.0.6 as the backend storage, completely bypassing the Titan/Rexter server running on 10.0.0.5. Can anyone confirm if this statement is correct?

If the statement is correct then the question I am really trying to answer is: If I want to connect to Titan by any means other than Rexster, how would I do it? I know I can use the titan java libraries, but does that not just create a new instance of titan again?

Regards
Richard

Stephen Mallette

unread,
Sep 13, 2013, 8:51:41 AM9/13/13
to aureliu...@googlegroups.com
Richard,
 
I could not connect using 10.0.0.5 and I could never understand why. I always had to use the ip address of cassandra. From what I can gather now, when I call TitanFactory.open(conf) I am actually creating a new instance of Titan on my local machine that is using 10.0.0.6 as the backend storage, completely bypassing the Titan/Rexter server running on 10.0.0.5. Can anyone confirm if this statement is correct?

If you use TitanFactory.open(conf) you are connecting directly to the graph in cassandra, bypassing Rexster, so you are correct.
 

If the statement is correct then the question I am really trying to answer is: If I want to connect to Titan by any means other than Rexster, how would I do it? I know I can use the titan java libraries, but does that not just create a new instance of titan again?

Your questions here confuse me a bit.  I hope I can clarify by simply stating:

1. you can connect to your graph by using TitanFactory.open(conf) thereby connecting to cassandra directly
2. you can connect to your graph via Rexster by way of RexPro (and the various available client apps) or REST 

HTH,

Stephen


--
You received this message because you are subscribed to the Google Groups "Aurelius" group.
To unsubscribe from this group and stop receiving emails from it, send an email to aureliusgraph...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Richard Kuiper

unread,
Sep 13, 2013, 8:56:04 AM9/13/13
to aureliu...@googlegroups.com
Hello

What I am trying to figure out is what is the point of having an instance of titan without rexster running on a server somewhere with cassandra as a backend? If calling TitanFactory.open() creates a new instance of the TitanGraph on whatever machine the code is running (not the titan without rexster instance) then why have a standalone titan instance running?

Regards
Richard

Stephen Mallette

unread,
Sep 13, 2013, 9:22:37 AM9/13/13
to aureliu...@googlegroups.com
I think there are some terminology issues here that are causing the disconnect (but i could be wrong).  

> If calling TitanFactory.open() creates a new instance of the TitanGraph on whatever machine the code is running (not the titan without rexster instance) 

If you mean "new instance" as in a new graph instance in cassandra, then that is not correct.  It will connect to the graph in the key space specified by the "conf" you pass in (which by default is "titan"). You might have many TitanGraph instances on many different machines (depending on what you are doing) but they all will reference the same graph instance in cassandra, assuming they are configured with the same keyspace. Does that help sort any of this out for you?


--

Richard Kuiper

unread,
Sep 13, 2013, 9:29:47 AM9/13/13
to aureliu...@googlegroups.com
Hehe

I understand there being on graph, which is stored in cassandra. I am struggling to explain it. The instance I am talking about is the Titan layer. You can install Titan on servers with say rexster or something. Is there no way to install Titan on a server somewhere can connect to it without using rexster? If there isn't then what is the point of having a Titan installation without rexster?

Regards
Richard

Antonio VonG

unread,
Sep 13, 2013, 9:43:13 AM9/13/13
to aureliu...@googlegroups.com
Hi Richard,

people embed Titan into their application,that way they can do direct gremlin queries within their application.

Regards,
Antonio

Stephen Mallette

unread,
Sep 13, 2013, 9:44:36 AM9/13/13
to aureliu...@googlegroups.com
You keep saying "install Titan".  I'm not sure what that means.  Titan is a code library that allows you to connect to some backend storage (cassandra, hbase, etc.).  If you want to "install Titan" on a server without Rexster, I guess that translates to, you would instantiate a TitanGraph in something like Tomcat, Jetty or some other "server" and install that somewhere.  

 If there isn't then what is the point of having a Titan installation without rexster?

Again, "Titan installation" really isn't a thing.  You might use a TitanGraph from a console app that does bulk loading with BatchGraph.  You might use a TitanGraph in Faunus.  You might use a TitanGraph instances in an agent that consumes data from a message queue and writes data to the cassandra.  But you really don't just "intall titan" somewhere.

Stephen

Stephen Mallette

unread,
Sep 13, 2013, 9:46:16 AM9/13/13
to aureliu...@googlegroups.com
Antonio says it well.  Titan is "embedded" into some other application.  Rexster embeds a TitanGraph.  Titan Server, embeds Rexster, which in turn embeds TitanGraph and Cassandra in the same JVM.  The point is that TitanGraph is "embedded" into something else.

Richard Kuiper

unread,
Sep 13, 2013, 9:49:53 AM9/13/13
to aureliu...@googlegroups.com
I think that is where my confusion kept coming in. I was under the impression that Titan was a service of some sort.

The name Titan Server made me think that it was this service running somewhere with cassandra as a backend and that clients would connect to titan to perform the queries.

Just so that I can get my ducks in a row, what exactly is Titan Server then? If Titan Server does not have Rexster embedded then what does it do?

Regards
Richard

Stephen Mallette

unread,
Sep 13, 2013, 9:55:26 AM9/13/13
to aureliu...@googlegroups.com
Just so that I can get my ducks in a row, what exactly is Titan Server then? If Titan Server does not have Rexster embedded then what does it do?

I think my last post following Antonio's explained that.  In that sense, Titan Server is something you "install", but recognize that you are really just installing Rexster with an embedded TitanGraph instance and Cassandra tightly integrated.  The structure of Titan Server is changing as you may have seen in posts sometime last week, so perhaps there will be less confusion on the topic going forward.

Antonio VonG

unread,
Sep 13, 2013, 10:02:04 AM9/13/13
to aureliu...@googlegroups.com
As for now, Titan server is "Titan the graph engine" with the cassandra/hbase etc. storage backends, which sits behind a rexster server.
BTW Titan is not what we usually called a database, because it relies on other databases to store the data.

Regards,
Antonio

Richard Kuiper

unread,
Sep 16, 2013, 3:28:42 AM9/16/13
to aureliu...@googlegroups.com
Thanks for the help everyone. That "oooooooohhhhhhh" bubble popped finally. Kind of strange though. I have been reading the documentation for a while now. I was really under the impression that titan was a service that ran. I wonder if other people starting out will have the same misunderstanding or not.

Regards
Richard

史晔翎

unread,
Jun 14, 2016, 7:39:55 AM6/14/16
to Aurelius
Took me several days to get out of the same impression. Still struggling!
Reply all
Reply to author
Forward
0 new messages