cancel
Showing results for 
Search instead for 
Did you mean: 

Head's Up! These forums are read-only. All users and content have migrated. Please join us at community.neo4j.com.

Default Node locking, also on label change? Or just on property creation/update?

Documentation in Java Reference 5.3 is clear enough:

  • When adding, changing or removing a property on a node or relationship a write lock will be taken on the specific node or relationship.
  • When creating or deleting a node a write lock will be taken for the specific node.
  • When creating or deleting a relationship a write lock will be taken on the specific relationship and both its nodes.

Is a label considered a node property as well?

  • Does adding, changing or removing a label cause taking a write lock?
  • Does adding, changing or removing a relationship type cause taking a write lock?
2 REPLIES 2

Yes, adding/removing labels requires a write lock on the node.
Relationship types cannot be added changed or removed from a relationship. A relationship can only have one type and it cannot change. (Though you could have multiple relationships between 2 nodes with different types). Relationship types aren't the same as node labels.

I would suggest updating the documentation to include

  • When adding, changing or removing a label on a node a write lock will be taken on the specific node.