You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Same issue as in #3960 but with apoc.refactor.cloneSubgraph() procedure.
When a clone node is made using apoc.refactor.cloneSubgraph() inside a transaction which is rolled back (manually or automatically), the clone survives the rollback, while other changes made inside the transaction do not. The effect is to break ACID compliance.
Expected Behavior (Mandatory)
Clone nodes should vanish with the rest of the transaction changes on rollback.
Actual Behavior (Mandatory)
Clone nodes survive as orphans exactly as made out of cloneSubgraph(), but without other (subsequent) changes made to them during the transaction.
How to Reproduce the Problem
This Cypher illustrates the fault:
CREATE (rootA:Root2{name:'A'}),
(rootB:Root2{name:'B'}),
(n1:Node2{name:'node1', id:1}),
(n2:Node2{name:'node2', id:2}),
(n3:Node2{name:'node3', id:3}),
(n4:Node2{name:'node4', id:4})
CREATE (rootA)-[:LINK]->(n1)-[:LINK]->(n2)-[:LINK]->(n3)
CREATE (rootB)-[:LINK]->(n4)
WITH rootA, rootB
CALL apoc.path.subgraphAll(rootA, {relationshipFilter:'LINK>'})
YIELD nodes, relationships
CALL apoc.refactor.cloneSubgraph(
nodes,
[rel in relationships WHERE type(rel) = 'LINK']
)
YIELD input, output as clone, error // this clone node survives(!)
SET clone.id = "clone". // however this change doesn't survive
RETURN 1/0 // rollback makes orphans
Steps (Mandatory)
Issue the above Cypher query in an empty DB
Check that the clone node survived: MATCH (n) RETURN n
Specifications (Mandatory)
Currently used versions
Versions
Community Edition
OS: macOS Ventura 13.6.4
Neo4j: 5.21.2
Neo4j-Apoc: 5.21.2
The text was updated successfully, but these errors were encountered:
Description
Same issue as in #3960 but with apoc.refactor.cloneSubgraph() procedure.
When a clone node is made using apoc.refactor.cloneSubgraph() inside a transaction which is rolled back (manually or automatically), the clone survives the rollback, while other changes made inside the transaction do not. The effect is to break ACID compliance.
Expected Behavior (Mandatory)
Clone nodes should vanish with the rest of the transaction changes on rollback.
Actual Behavior (Mandatory)
Clone nodes survive as orphans exactly as made out of cloneSubgraph(), but without other (subsequent) changes made to them during the transaction.
How to Reproduce the Problem
This Cypher illustrates the fault:
Steps (Mandatory)
Specifications (Mandatory)
Currently used versions
Versions
Community Edition
The text was updated successfully, but these errors were encountered: