Bram Schuur created TINKERPOP-2781:
--------------------------------------

             Summary: Nested __.or() query causes excessive cpu usage 
CloseableIterator.closeIterator
                 Key: TINKERPOP-2781
                 URL: https://issues.apache.org/jira/browse/TINKERPOP-2781
             Project: TinkerPop
          Issue Type: Improvement
          Components: process
    Affects Versions: 3.5.4, 3.6.1, 3.4.13
            Reporter: Bram Schuur
         Attachments: Screenshot from 2022-08-04 15-26-02.png

In our application we construct a query of the form (nested or queries):

 
{code:java}
__.or(<P1>, __.<P2>.or(<P3>, __.<P4>.or(<P5>), <.....>)))
{code}
 

The moment the amount of nestings starts increasing performance starts 
degrading disproportionally (starting as soon as 4 nestings, depending on the 
size of the input). Investigation with jprofiler gives the following timing, 
showing that a disproportionate amount of time is spent closing the traversal:

!Screenshot from 2022-08-04 15-26-02.png!

Hypothesis is that the complete traversal is closed whenever a 
TraversalUtil.test() has been performed, making in increasingly slower when the 
traversal becomes bigger.

 

This all seems related to https://issues.apache.org/jira/browse/TINKERPOP-2704



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to