toggle quoted messageShow quoted text
You did not state whether you studied https://docs.janusgraph.org/advanced-topics/eventual-consistency/#data-consistency and whether that would fullfil your needs.
Best wishes, Marc
Op donderdag 7 januari 2021 om 16:18:55 UTC+1 schreef Timon Schneider:
I have a question about locking data through Janusgraph.
Here’s the problem:
* We have a vertex with the label “type” with several properties
* Types have one edge “hasVersion” to a vertex with a label “version”
* This version vertex has a boolean property “published”.
* The type’s properties should not be allowed to be changed if the version’s published property is true.
We’re dealing with many concurrent user’s who might changes the type’s properties and set the version’s published property to true at the same time. And we need to be sure that the type’s properties are not change once it’s published.
Is there a way to lock the version vertex once the type is being changed in a transaction? This would make sure that the type is not published by a concurrent user while it is being changed.
We’re using the following configuration. Also we’re setting all relevant elements to ConsistencyModifier.LOCK through graph.openManagement().setConsistency.
Thanks in advance,