Skip to content

Java API: newEdge() on an immutable vertex can cause problems with common patterns #1218

@lvca

Description

@lvca

Adding and removing edges on immutable vertices is allowed, because it's not the vertex itself to be saved, but internally the vertex is modified first.

This means if you're using code that add multiple edges from an immutable vertex, you keep adding edges to the same vertex that doesn't carry the pending changes.

A minor review of the API should be done to mandate only mutable vertices can add/remove edges.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions