isFitted=false in profile, while we have corresponding mixed index
Ankur Goel <ankur...@...>
gremlin> g.V().has("vlabel","taglead").has("leadid","53012").bothE().has("reason","mobile").inV().has("vlabel","taglead").has("leadid","72783").profile() ==>Traversal Metrics Step Count Traversers Time (ms) % Dur ============================================================================================================= JanusGraphStep([],[vlabel.eq(taglead), leadid.e... 1 1 250.100 53.70 \_condition=(vlabel = taglead AND leadid = 53012) \_isFitted=true \_query=multiKSQ[1]@2147483647 \_index=c-v-index-vlabel-leadid \_orders=[] \_isOrdered=true optimization 200.259 backend-query 1 4.800 \_query=c-v-index-vlabel-leadid:multiKSQ[1]@2147483647 JanusGraphVertexStep([reason.eq(mobile)]) 43 43 56.260 12.08 \_condition=(reason = mobile AND EDGE AND visibility:normal) \_isFitted=false \_vertices=1 \_query=org.janusgraph.diskstorage.keycolumnvalue.SliceQuery@801a60ee \_orders=[] \_isOrdered=true optimization 7.621 backend-query 81 4.639 \_query=org.janusgraph.diskstorage.keycolumnvalue.SliceQuery@801a60ee EdgeVertexStep(IN) 43 43 2.002 0.43 HasStep([vlabel.eq(taglead), leadid.eq(72783)]) 157.337 33.79 >TOTAL - - 465.701 - gremlin> g.V().has("vlabel","taglead").has("leadid","53012").bothE().has("reason","mobile").profile() ==>Traversal Metrics Step Count Traversers Time (ms) % Dur ============================================================================================================= JanusGraphStep([],[vlabel.eq(taglead), leadid.e... 1 1 1.522 43.90 \_condition=(vlabel = taglead AND leadid = 53012) \_isFitted=true \_query=multiKSQ[1]@2147483647 \_index=c-v-index-vlabel-leadid \_orders=[] \_isOrdered=true optimization 1.044 JanusGraphVertexStep([reason.eq(mobile)]) 43 43 1.945 56.10 \_condition=(reason = mobile AND EDGE AND visibility:normal) \_isFitted=false \_vertices=1 \_query=org.janusgraph.diskstorage.keycolumnvalue.SliceQuery@801a60ee \_orders=[] \_isOrdered=true optimization 0.054 >TOTAL - - 3.468 - gremlin> while we have created mixed index on reason. Please guide what is causing isFitted=false |
|
Ankur Goel <ankur...@...>
is there a different way for indexes on edge? On Wednesday, November 1, 2017 at 2:12:30 PM UTC+5:30, Ankur Goel wrote:
|
|
bhawesh...@...
Please reply to the solution of this problem. I am also facing the same problem On Wednesday, November 1, 2017 at 2:12:30 PM UTC+5:30, Ankur Goel wrote:
|
|
Bhawesh Agarwal <bhawesh....@...>
Please Anyone can explain how to give indexing in this query. I am facing same problem. On Wednesday, 1 November 2017 14:12:30 UTC+5:30, Ankur Goel wrote:
|
|
tpr...@...
Your are inside a traversal so you have to use vertex-centric indexes.
Mixed and composite can be use when you enter in a graph (g.V().has... Or g.E().has...) Vertex centric can be use on a traversal (...outE().has...) http://docs.janusgraph.org/latest/indexes.html#vertex-indexes |
|
Ankur Goel <ankur...@...>
Bhawesh, You need to create vertex-centric index to work on traversal. Its a chained process, till bothE() its using mixed/composite index, after this for traversal on edges you need vertex centric index. graph.tx().rollback() //Never create new indexes while a transaction is active mgmt = graph.openManagement() reason = mgmt.getPropertyKey('reason') label = mgmt.getEdgeLabel('edgelabel') mgmt.buildEdgeIndex(label, 'edge', Direction.BOTH, Order.decr, reason) mgmt.commit() For detailed info please read: http://docs.janusgraph.org/latest/indexes.html#vertex-indexes ~ On Tuesday, November 28, 2017 at 10:29:35 PM UTC+5:30, Bhawesh Agarwal wrote:
|
|