Skip to main content
QUICK REVIEW

[Paper Review] Antidote SQL: Relaxed When Possible, Strict When Necessary

Pedro Miguel Sousa Lopes, João Sousa|arXiv (Cornell University)|Feb 10, 2019
Distributed systems and fault tolerance22 references4 citations
TL;DR

Antidote SQL enables application developers to relax SQL consistency when safe, while enforcing primary key, foreign key, and check constraints under relaxed semantics to ensure correctness. It uses a schema-driven concurrency model and CRDT-based conflict resolution to minimize coordination, achieving high availability and low latency in geo-replicated systems without sacrificing data integrity.

ABSTRACT

Geo-replication poses an inherent trade-off between low latency, high availability and strong consistency. While NoSQL databases favor low latency and high availability, relaxing consistency, more recent cloud databases favor strong consistency and ease of programming, while still providing high scalability. In this paper, we present Antidote SQL, a database system that allows application developers to relax SQL consistency when possible. Unlike NoSQL databases, our approach enforces primary key, foreign key and check SQL constraints even under relaxed consistency, which is sufficient for guaranteeing the correctness of many applications. To this end, we defined concurrency semantics for SQL constraints under relaxed consistency and show how to implement such semantics efficiently. For applications that require strict SQL consistency, Antidote SQL provides support for such semantics at the cost of requiring coordination among replicas.

Motivation & Objective

  • Address the trade-off between low latency, high availability, and strong consistency in geo-replicated databases.
  • Enable application developers to relax SQL consistency where safe, while preserving database integrity through constraints.
  • Provide a schema-driven approach to control concurrency semantics without requiring complex coordination.
  • Ensure correctness of applications under relaxed consistency by enforcing primary key, foreign key, and check constraints.
  • Minimize coordination overhead while supporting both relaxed and strict consistency modes based on application needs.

Proposed method

  • Extend AQL (Antidote SQL's SQL-like interface) with DDL extensions to specify concurrency semantics and constraint enforcement policies.
  • Use Parallel Snapshot Isolation (PSI) with integrity invariants to support concurrent, causally-ordered transactions across geo-distributed sites.
  • Leverage CRDTs (Conflict-free Replicated Data Types) to enable safe merging of concurrent updates with user-defined merge policies.
  • Design coordination-free algorithms for enforcing referential integrity across distributed shards and replicas.
  • Implement constraint enforcement semantics that restrict only conflicting updates, preserving high concurrency where possible.
  • Integrate with AntidoteDB as the underlying key-object store with native CRDT and escrow data type support.

Experimental results

Research questions

  • RQ1How can SQL consistency be relaxed in geo-replicated databases without compromising data integrity?
  • RQ2What concurrency semantics are safe and efficient for enforcing primary key, foreign key, and check constraints under weak consistency?
  • RQ3Can a schema-driven approach eliminate the need for complex static analysis or runtime instrumentation to guide consistency relaxation?
  • RQ4How can referential integrity be maintained across distributed nodes without requiring coordination among replicas?
  • RQ5What is the performance overhead of enforcing constraints under relaxed consistency compared to traditional strong-consistency models?

Key findings

  • Antidote SQL allows developers to specify when and how SQL consistency can be relaxed using schema-level concurrency semantics, reducing coordination overhead.
  • The system enforces primary key, foreign key, and check constraints even under relaxed consistency, ensuring correctness for many real-world applications.
  • CRDT-based conflict resolution enables safe merging of concurrent updates with user-defined policies, supporting high availability and low latency.
  • The implementation of referential integrity uses coordination-free algorithms that maintain consistency across distributed shards and replicas.
  • Preliminary evaluation shows negligible overhead for insert and update operations under optimistic foreign key enforcement, though delete operations incur measurable cost.
  • The system achieves a balance between performance and correctness by restricting coordination only when necessary, while still allowing high concurrency in safe cases.

Better researchstarts right now

From reading papers to final review, dramatically reduce your research time.

No credit card · Free plan available

This review was created by AI and reviewed by human editors.