RegisterSign In
By Aris Setyawan (arissety) on Jun 9, 2010 2:16 PM.
What kind of locking

What kind of locking used by Mckoi DDB? What the relation of Consensus Function with Mckoi locking mechanism?
By Tobias Downer (toby) on Jun 9, 2010 6:01 PM.
An important goal of a distributed system is to reduce the amount of time spent in lock contention. If a system needs lots of locks to achieve consistency then you risk deadlocks and/or you bump into bottlenecks to scalability. You can achieve absolute consistency with something like global locking, but then the performance of the entire system is dependent on the latency of that lock. It's a difficult balance. When you remove the locks you improve the throughput and scalability but now transactional consistency is impossible (you have no way of knowing if the data as a whole conforms to the schema).

The current thinking at places like Google is to define data consistency in a very strict set of rules and bounds and use a global locking mechanism to enforce these rules. This makes building complex consistent data structures very difficult. We take a different approach, allowing a data model to freely define its own consistency rules (and time spent in lock contention). We handle the problem of contentions becoming a bottleneck by making the data model malleable, allowing data to be moved very easily between contentious parts through logical sharding.

But basically what it boils down to is this; Reads never lock, writes never lock except commits which will lock on their path (ie. concurrent path commits are impossible). There are no global locks or inter-path locks. It's the most flexible way I could think of to cover a balance of the two worlds.
Please sign in or register to post in this topic.
The text on this page is licensed under the Creative Commons Attribution 3.0 License. Java is a registered trademark of Oracle and/or its affiliates.
Mckoi is Copyright © 2000 - 2017 Diehl and Associates, Inc. All rights reserved.