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

Bytecode object shallow copied when traversals are cloned

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 3.3.0, 3.2.5
    • 3.3.0, 3.2.6
    • process
    • None

    Description

      The bytecode member of traversal objects are only shallow copied when a traversal is cloned. This causes issues because any updates to the clone will be propagated to cloned traversal.

      gremlin> g = TinkerGraph.open().traversal()
      ==>graphtraversalsource[tinkergraph[vertices:0 edges:0], standard]
      gremlin> traversal = g.V().out();null
      ==>null
      gremlin> clonedTraversal = traversal.asAdmin().clone();null
      ==>null
      gremlin> clonedTraversal.out().out();null
      ==>null
      gremlin> traversal.getBytecode()
      ==>[[], [V(), out(), out(), out()]]
      gremlin> clonedTraversal.getBytecode()
      ==>[[], [V(), out(), out(), out()]]
      

      Attachments

        Issue Links

          Activity

            People

              twilmes Ted Wilmes
              twilmes Ted Wilmes
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: