Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
    Florian Hockmann
    @FlorianHockmann
    @li-boxuan There is really not much documentation about that, but you can find some information here: https://docs.janusgraph.org/advanced-topics/hadoop/
    Boxuan Li
    @li-boxuan
    Thanks. I was trying to understand more about the underlying mechanism behind using hadoop-gremlin with Januagraph. My guess is that functionality is not related to the janusgraph-hadoop package, but something provided by gremlin. Please correct me if I am wrong.
    Florian Hockmann
    @FlorianHockmann
    hadoop-gremlin provides most of the implementation for working with a TinkerPop graph (like JanusGraph) on Spark. It contains for example the SparkGraphComputer for this. The janusgraph-hadoop package contains everything necessary to use hadoop-gremlin together with JanusGraph, mainly Hadoop Input Formats for the different storage backends like CQL or HBase. So, they allow hadoop-gremlin to use data stored in JanusGraph
    That also means that most of TinkerPop's documentation on hadoop-gremlin applies to JanusGraph. The JanusGraph docs for this mostly only describe the JanusGraph specific config for this
    Boxuan Li
    @li-boxuan
    That’s very helpful. Thank you!
    Stu Btwotwo
    @stub22
    Howdy folks, I am seeing some JG behavior that I did not expect, but I could be misinterpreting things.
    It appears that the value of .id() for a vertex can change when the values of its ordinary properties are updated.
    Does that sound correct? Do the JG docs say anywhere that an .id() is always immutable, or only mutable when _ ?
    If y'all say the .id() should never change, then I will go back and recheck the output more carefully.
    But right now it looks like it sometimes changes. Basically I create a vertex, commit it, then run another transaction
    to modify the properties on the vertex. After that second transaction, sometimes the vertex has a different .id(). Is that expected
    behavior or not? This test is using a Berkeley-DB backend, with no indexes, no schemas, and no customization -
    just vanilla JG 0.4.0.
    LoveMyDouDou
    @LoveMyDouDou
    when I run OLAP Traversals with Spark Local , dependency conflict comes : Caused by: java.lang.NoSuchMethodError: net.jpountz.lz4.LZ4BlockInputStream.<init>(Ljava/io/InputStream;Z)V , who knows how to fix ?
    Boxuan Li
    @li-boxuan
    @stub22 I am new to JG but I guess maybe your vertex is partitioned
    Stu Btwotwo
    @stub22
    @li-boxuan Thanks for the thought. I am running standalone on a single machine, single JG JVM, with a single Berkeley-DB backend.
    I am sending my transactions from a Java/Scala client using gremlin-driver. I also have gremlin-console open, talking to that same JG instance (again via gremlin-driver), which can lead to some transaction contention. But with only one backend DB instance, I presume there can be no partitioning, per se.
    Florian Hockmann
    @FlorianHockmann
    @stub22 The vertex ids should never change. Are you sure that you're always looking at the same vertex and not two different vertices with the same properties?
    Stu Btwotwo
    @stub22
    @FlorianHockmann - Thank you. It is possible that there were two vertexes with the same properties, as you say.
    The issue has stopped occurring, for the moment. If it reoccurs I will study it more carefully, starting with the presumption
    that .id() cannot change.
    ehds
    @ehds_gitlab
    Does janusgraph plugin gephi support Geoshape? When I output the graph of the Gods, I got stackoverflow error.
    ehds
    @ehds_gitlab
    gremlin> :> graph
    ==>standardjanusgraph[berkeleyje:/home/ehds/Programs/janusgraph-0.4.0-hadoop2/conf/../db/berkeley]
    20:38:36 WARN  org.janusgraph.graphdb.transaction.StandardJanusGraphTx  - Query requires iterating over all vertices [()]. For better performance, use indexes
    java.lang.StackOverflowError
    Type ':help' or ':h' for help.
    Display stack trace? [yN]
    Yarden Bar
    @ayashjorden

    Hi all,
    I have two indices with some property indexed by both of them:
    Idx-1: prop1, prop2, prop3
    Idx-2: prop1

    My query: g.V().or(__.has(‘prop1’,’SEARCH_TERM'),__.has(‘prop2,’SEARCH_TERM')).valueMap(true);
    Results in Query requires iterating over all vertices [(prop1 = SEARCH_TERM)]. For better performance, use indexes

    What am I doing wrong?

    ehds
    @ehds_gitlab
    For better performance,you should build index for prop1 and prop2.
    Yarden Bar
    @ayashjorden
    Yes, that’s what I ended up doing, thank you for confirming my thoughts
    qiuqingyu
    @qiuqingyu
    hello i am new in JanusGraph. When i use Janusgraph in Apache Atlas, i found a question, the error is :
    Could not find a type identifier for the class : class org.apache.atlas.typesystem.types.DataTypes$TypeCategory. Make sure the value to serialize has a type identifier registered for its class.
    org.apache.tinkerpop.shaded.jackson.databind.JsonMappingException: Could not find a type identifier for the class : class org.apache.atlas.typesystem.types.DataTypes$TypeCategory. Make sure the value to serialize has a type identifier registered for its class.
    at org.apache.tinkerpop.shaded.jackson.databind.ser.DefaultSerializerProvider._wrapAsIOE(DefaultSerializerProvider.java:509)
    at org.apache.tinkerpop.shaded.jackson.databind.ser.DefaultSerializerProvider._serialize(DefaultSerializerProvider.java:482)
    at org.apache.tinkerpop.shaded.jackson.databind.ser.DefaultSerializerProvider.serializeValue(DefaultSerializerProvider.java:319)
    at org.apache.tinkerpop.shaded.jackson.databind.ObjectMapper._configAndWriteValue(ObjectMapper.java:3893)
    at org.apache.tinkerpop.shaded.jackson.databind.ObjectMapper.writeValue(ObjectMapper.java:3164)
    at org.apache.tinkerpop.gremlin.structure.io.graphson.GraphSONWriter.writeVertex(GraphSONWriter.java:82)
    at org.apache.tinkerpop.gremlin.structure.io.graphson.GraphSONWriter.writeVertices(GraphSONWriter.java:110)
    at org.apache.tinkerpop.gremlin.structure.io.graphson.GraphSONWriter.writeGraph(GraphSONWriter.java:71)
    at org.apache.tinkerpop.gremlin.structure.io.graphson.GraphSONIo.writeGraph(GraphSONIo.java:83)
    at org.apache.tinkerpop.gremlin.structure.io.Io$writeGraph.call(Unknown Source)
    at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:47)
    at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:116)
    at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:128)
    at groovysh_evaluate.run(groovysh_evaluate:3)
    at org.codehaus.groovy.vmplugin.v7.IndyInterface.selectMethod(IndyInterface.java:236)
    at org.codehaus.groovy.tools.shell.Interpreter.evaluate(Interpreter.groovy:71)
    at org.codehaus.groovy.tools.shell.Groovysh.execute(Groovysh.groovy:196)
    at org.apache.tinkerpop.gremlin.console.GremlinGroovysh.super$3$execute(GremlinGroovysh.groovy)
    at sun.reflect.GeneratedMethodAccessor14.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:498)
    at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:98)
    at groovy.lang.MetaMethod.doMethodInvoke(MetaMethod.java:325)
    at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:1225)
    at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.invokeMethodOnSuperN(ScriptBytecodeAdapter.java:145)
    at org.apache.tinkerpop.gremlin.console.GremlinGroovysh.execute(GremlinGroovysh.groovy:72)
    at org.codehaus.groovy.tools.shell.Shell.leftShift(Shell.groovy:122)
    at org.codehaus.groovy.tools.shell.ShellRunner.work(ShellRunner.groovy:95)
    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:62)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:498)
    at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:98)
    at groovy.lang.MetaMethod.doMethodInvoke(MetaMethod.java:325)
    at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:1225)
    at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.invokeMethodOnSuperN(ScriptBytecodeAdapter.java:145)
    at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.invokeMethodOnSuper0(ScriptBytecodeAdapter.java:165)
    at org.codehaus.groovy.tools.shell.InteractiveShellRunner.work(InteractiveShellRunner.groovy:130)
    at org.codehaus.groovy.tools.shell.ShellRunner.run(ShellRunner.groovy:59)
    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:62)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.
    how can i solve it? thank you very much
    fgadaleta
    @fgadaleta
    hi all, is there a python library that implements the common graph algorithms on gremlin-janusgraph?
    Florian Hockmann
    @FlorianHockmann
    @qiuqingyu You probably just need to register a serializer for Atlas specific types as JanusGraph itself doesn't know about them. If the Atlas docs don't contain anything on this matter, I would ask in their support channels
    @fgadaleta What do you mean with common graph algorithms? Some algorithms like shortest path are part of TinkerPop and therefore also work on JanusGraph and can also be used from Python with gremlin-python
    fgadaleta
    @fgadaleta
    @qiuqingyu finding the connected components of a graph or the shortest path between any two nodes, the betweeness centrality , etc. ..
    Florian Hockmann
    @FlorianHockmann
    Most of that is documented in the TinkerPop docs. The recipes are usually a good place to find information on frequently used patterns:
    fgadaleta
    @fgadaleta
    @FlorianHockmann thanks i saw that but that's not in python
    Florian Hockmann
    @FlorianHockmann
    The steps are all also available in Gremlin-Python, so it should work basically the same way
    fgadaleta
    @fgadaleta
    there's no recipes in Python directly that you know of, @FlorianHockmann
    ?
    qiuqingyu
    @qiuqingyu
    @FlorianHockmann sorry, I didn't find the serializer for Atlas in the Atlas docs. I have to trouble you to help me.
    Florian Hockmann
    @FlorianHockmann
    @fgadaleta The recipes are just documentation. They are not implemented in any library directly. You can simply use code showed there also in Python if youuse gremlin-python
    @qiuqingyu I can't really help you as I don't know anything about Atlas. You'll have to ask their support for help (or Google as you're probably not the first one who encounters this problem)
    fgadaleta
    @fgadaleta
    I keep getting WARN org.janusgraph.graphdb.transaction.StandardJanusGraphTx - Query requires iterating over all vertices [()]. For better performance, use indexes
    what am i doing wrong?
    Florian Hockmann
    @FlorianHockmann
    It simply means that your query isn't using an index and therefore has to iterate over all vertices which isn't a good idea for larger graphs
    fgadaleta
    @fgadaleta
    ah it must come from graphexp as i am using it as a "dashboard"
    qiuqingyu
    @qiuqingyu
    @FlorianHockmann I found the serializer for Atlas. And I registerd it. But the error still exist.
    Yarden Bar
    @ayashjorden
    What is the correct way to index labels, to fulfill g..V().hasLabel(LABEL_STRING)
    ?
    pra527vin
    @pra527vin
    I have been using janusgraph 0.4.0 with cassandra 3.1.1 as storage backend and solr 7.0.0 while doing direct index query after update sometimes old value of property are returned and sometimes new values of properties are returned
    for example
    if have Vertex Product with properties productName= xyz soap and status = ACTIVE ,availability = InStock
    I have indexed productName and status
    when I update availability = OutOfStock
    then when I make direct index query Product vertex will sometime return
    productName= xyz soap and status = ACTIVE ,availability = InStock
    then sometimes return
    productName= xyz soap and status = ACTIVE ,availability = OutOfStock
    Florian Hockmann
    @FlorianHockmann
    @ayashjorden It's not possible to index just a label. Indices always index properties. There is an open issue for this feature request: #283
    So, you currently have to implement a workaround where you for example add the label additionally as a property that you can then index
    @qiuqingyu Did you register it on the client and the server?
    qiuqingyu
    @qiuqingyu
    @FlorianHockmann yes, I found the code in Atlas.
    janusConfig.addProperty("attributes.custom.attribute1.attribute-class", TypeCategory.class.getName());
    janusConfig.addProperty("attributes.custom.attribute1.serializer-class", TypeCategorySerializer.class.getName());
        //not ideal, but avoids making large changes to Atlas
        janusConfig.addProperty("attributes.custom.attribute2.attribute-class", ArrayList.class.getName());
        janusConfig.addProperty("attributes.custom.attribute2.serializer-class", SerializableSerializer.class.getName());
    
        janusConfig.addProperty("attributes.custom.attribute3.attribute-class", BigInteger.class.getName());
        janusConfig.addProperty("attributes.custom.attribute3.serializer-class", BigIntegerSerializer.class.getName());
    
        janusConfig.addProperty("attributes.custom.attribute4.attribute-class", BigDecimal.class.getName());
        janusConfig.addProperty("attributes.custom.attribute4.serializer-class", BigDecimalSerializer.class.getName());
    Florian Hockmann
    @FlorianHockmann
    @qiuqingyu What are you doing with this config?
    qiuqingyu
    @qiuqingyu
    I want to export data from janusgraph with graph.io(IoCore.graphson()).writeGraph("tinkerpop-modern.json");, but an ERROR occurred.
    @FlorianHockmann
    Florian Hockmann
    @FlorianHockmann
    @qiuqingyu So how do you create the graph object?
    pra527vin
    @pra527vin
    Is there a way i can change replication factor when I have already created schema and I have data which is in production?
    I have implemented cassandra 3.11.1 and janusgraph 0.4.0 on same node
    Florian Hockmann
    @FlorianHockmann
    @pra527vin Yes, that's possible, but not through JanusGraph config. You'll have to do it directly in Cassandra. So, you can consult the usual Cassandra docs on that: Modifying the replication factor
    Boxuan Li
    @li-boxuan
    Hi, is it safe to say that vertex-centric indexes take very little space? I am guessing that a vertex-centric index is essentially a sorting criterion that regulates how edges are sorted