On 19 January 2017 at 03:24, Marko Rodriguez <[email protected]> wrote:

> Hi,
>
> OrientDB can do distributed transactions across nodes. What do you mean
> for connections?
>
> So, I’m not so skilled when it comes to transactions and the like so bear
> with me…
>
> One of the models I want to push is that each worker in GraphActors will
> have a Graph “connection.” That is:
>
> configuration.setProperty(“host”,worker.address())
> Graph graph = GraphFactory.open(configuration); // Graph = “connection"
>
>
> This way, the worker is always talking directly to the node it is
> physically executing at. Moreover, it means that its Partition is the data
> contained at the node in the cluster. Everything is processed locally with
> GraphActors.
>
> Now, lets say we do a muting traversal such as:
>
> g.V().as(‘a’).out(‘knows’).as(‘b’).
>   addE(‘likes’).from(‘a’).to(‘b’)
>
>
>
> So, this will have it such that each Graph “connection” will have writes
> to it. Now lets say we want to “globally commit” such that each Graph
> “connection” commits its transaction but if any particular one fails, they
> all fail …. or something like that. That is, how can we (OrientDB and/or
> TinkerPop) enable transaction guarantees across multiple Graph
> "connections"?
>

In OrientDB the distributed transaction starts from any node (multi-master)
that acts as coordinator for the transaction. So the client has to execute
all the operation inside the same connection to the coordinator server. At
that point the coordinator divide the operation based on
sharding/replication and send them to all the involved nodes.

Once the write quorum is satisfied (by default is "majority" of the
servers), then the coordinator sends a final commit (2 phase commit) to the
servers. If any server doesn't agree with the quorum, it's forced to have
the same state.

If the coordinator crashes before to send the final ok, well each server
has a timeout per transaction and after a while they rollback
autonoumously.

So if all the mutations are sent through the same connection, then OrientDB
can execute all of them as an ACID distributed transaction.


>
> Thanks,
> Marko.
>
> http://markorodriguez.com
>
>
>
>
>>
>> Thanks Luca,
>> Marko.
>>
>> http://markorodriguez.com
>>
>
> Luca
>
> --
> You received this message because you are subscribed to the Google Groups
> "Gremlin-users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To view this discussion on the web visit https://groups.google.com/d/ms
> gid/gremlin-users/CAGud208pLzs9-OT%2BoiuTCKGimXFkaLoyKoAPrro
> mVLD1ny72kg%40mail.gmail.com
> <https://groups.google.com/d/msgid/gremlin-users/CAGud208pLzs9-OT%2BoiuTCKGimXFkaLoyKoAPrromVLD1ny72kg%40mail.gmail.com?utm_medium=email&utm_source=footer>
> .
> For more options, visit https://groups.google.com/d/optout.
>
>
> --
> You received this message because you are subscribed to the Google Groups
> "Gremlin-users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To view this discussion on the web visit https://groups.google.com/d/ms
> gid/gremlin-users/18D3D712-6AC9-471D-AAE6-8FFDB4BE4A39%40gmail.com
> <https://groups.google.com/d/msgid/gremlin-users/18D3D712-6AC9-471D-AAE6-8FFDB4BE4A39%40gmail.com?utm_medium=email&utm_source=footer>
> .
>
> For more options, visit https://groups.google.com/d/optout.
>

Reply via email to