Sequenced Message Streams for ACID Distributed Transactions
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Implementing ACID compliant transactions in distributed computing systems, particularly distributed databases, is challenging due to the limitations of existing techniques like the Saga design pattern and Two-Phase Commit protocol.
Innovation Solution
A system with a sequencer that communicates an atomic message sequence to multiple service instances, where each instance processes messages through a local queue and a state machine to execute distributed transactions, ensuring ACID compliance.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Reliability
If the Two-Phase Commit protocol is used to ensure ACID compliance in distributed transactions, then transaction reliability is improved, but system complexity and performance overhead increase
Solution Approach 1:
The patent introduces a sequencer as an intermediary component that receives transaction requests, assigns sequence numbers, and broadcasts ordered transaction logs to all service instances. This mediator simplifies the distributed transaction coordination by centralizing the ordering logic, eliminating the need for complex two-phase commit protocols while maintaining ACID compliance through the sequential ordering mechanism.
2Device complexity
If the Saga design pattern is used to handle distributed transactions, then system complexity is reduced, but transaction atomicity and reliability deteriorate
Solution Approach 1:
The patent performs preliminary ordering of transactions through the sequencer before execution. By assigning sequence numbers and establishing a total order of transaction logs in advance, the system ensures that transactions are executed in a predetermined sequence across all service instances. This preliminary ordering guarantees atomicity without requiring the complex compensation mechanisms of the Saga pattern.
3Reliability
If distributed databases are implemented to provide redundancy and fault tolerance, then system reliability is improved, but achieving ACID compliant transactions becomes more difficult
Solution Approach 1:
The patent segments the distributed transaction system into independent service instances, each maintaining its own local state and processing transactions independently based on the sequentially ordered logs received from the sequencer. This segmentation allows each instance to handle transactions locally without complex inter-instance coordination, simplifying ACID compliance while maintaining fault tolerance through redundancy.
Data Source
AI summary
A system for processing distributed transactions is provided. The system includes a sequencer that communicates an atomic message stream to multiple different service instances. The service instances each process the messages from the message stream into a local queue. Each service instance also executes a state machine by reading messages from a queue and transitioning between states in the state machine while also performing one or more operations in connection with performing a distributed transaction.


