Uploaded image for project: 'TinkerPop'
  1. TinkerPop
  2. TINKERPOP-1490

Provider a Future based Traversal.async(Function<Traversal,V>) terminal step

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Major
    • Resolution: Done
    • Affects Version/s: 3.2.2
    • Fix Version/s: 3.2.4
    • Component/s: process
    • Labels:
      None

      Description

      Matthias Broecheler had the idea of adding a Traversal.async() method. This is important for not only avoiding thread locking on a query in Gremlin, but also, it will allow single threaded language variants like Gremlin-JavaScript to use callbacks for processing query results.

      Future<List<String>> result = g.V().out().values("name").async(Traversal::toList)
      
      Future<List<String>> result = g.V().out().name.async{it.toList()}
      
      g.V().out().values('name').async((err,names) => {
        // I don't know JavaScript, but ...
        return list(names);
      }) 
      

      ...

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                spmallette stephen mallette
                Reporter:
                okram Marko A. Rodriguez
              • Votes:
                1 Vote for this issue
                Watchers:
                7 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: