Re: Where are my edges?


Yair Ogen <yair...@...>
 

I did comm at the end:

graph.tx().commit()

graph.close

On Thu, Aug 31, 2017 at 10:59 AM, HadoopMarc <marc.d...@...> wrote:
All graph mutations are realized within a (hidden) transaction. You have to commit() the transaction before the changes are visible to other clients. So, look for .commit methods in the gremlin-scala API .

Cheers,    Marc

Op donderdag 31 augustus 2017 09:33:33 UTC+2 schreef ya...@...:
I am using gremlin-scala.

I connect to remote janus server that forked cassandra using:


val conf = new BaseConfiguration()
conf.setProperty("storage.backend", "cassandra")
conf.setProperty("storage.hostname", "my-ip")
conf.setProperty("index.search.hostname", "my-ip")
val graph = JanusGraphFactory.open(conf).asScala

I create vertexes and edges:

val cityA = graph + (location, name -> "City-A", population -> 400000)
val cityB= graph + (location, name -> "CityB", population -> 300000)


cityB<-- ("Road", distance -> 92) --> cityA 

and If I query these - everything is ok.

however, if I look up the vertexes in another client:

val telAviv = graph.V().has(name,"TelAviv").head()

my queries (for example find all paths from V1 to V2) don't work.

It's as it they are not stored in the DB and are only available during the same run that created them.

What am I doing wrong?

--
You received this message because you are subscribed to a topic in the Google Groups "JanusGraph users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/janusgraph-users/fONPVU9xkHE/unsubscribe.
To unsubscribe from this group and all its topics, send an email to janusgraph-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/janusgraph-users/38fbaf0f-e670-409e-b6a2-81e0ecab7b6d%40googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

Join {janusgraph-users@lists.lfaidata.foundation to automatically receive all group messages.