Distributed Transaction Processing via Message Queue Decoupling

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Existing distributed transaction processing methods based on message queues face challenges such as poor performance, complex implementation, limited usability, and difficulty in deployment across different systems, particularly due to the limitations of the XA two-phase commit scheme, TCC scheme, BEN scheme, and reliable-message eventual consistency scheme.

Innovation Solution

A distributed transaction processing method and system that generates a target compressed package based on configuration information from business request and execution servers, allowing for separate deployment of the distributed transaction processing component and message transmission path, thereby improving usability and deployment efficiency.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Reliability

If the XA two-phase commit scheme is used to ensure distributed transaction consistency, then transaction reliability is improved, but system performance deteriorates

Engineering Contradiction:
Improvetransaction consistencyVSAvoidsystem performance
Core Design Contradiction:
ReliabilityVSProductivity

Solution Approach 1:

The patent introduces a message queue as an intermediary component between the transaction manager and resource servers. The transaction coordinator sends transaction requests and status notifications through the message queue, which decouples the synchronous two-phase commit protocol from the actual transaction execution. This allows the system to maintain transaction consistency guarantees while improving performance by avoiding direct synchronous blocking between components.

Inventive Principle:
Principle #24Intermediary (Mediator)

2Reliability

If the TCC scheme is implemented to achieve distributed transaction consistency, then transaction reliability is improved, but implementation complexity increases

Engineering Contradiction:
Improvetransaction consistencyVSAvoidcode logic complexity
Core Design Contradiction:
ReliabilityVSDevice complexity

Solution Approach 1:

The patent extracts the complex transaction coordination logic from business applications and encapsulates it in a dedicated transaction manager component. The manager handles Try, Confirm, and Cancel operations centrally, while business services only need to implement simple interface methods. This separation of concerns reduces the complexity burden on business code while maintaining reliable distributed transaction processing.

Inventive Principle:
Principle #2Taking out (Extraction)

3Productivity

If the reliable-message eventual consistency scheme is used to solve transaction consistency, then system performance is improved, but adaptability deteriorates due to specific message queue requirements

Engineering Contradiction:
Improvesystem performanceVSAvoidmessage queue selection flexibility
Core Design Contradiction:
ProductivityVSAdaptability or versatility

Solution Approach 1:

The patent designs a universal transaction manager that can work with multiple types of message queues (RocketMQ, Kafka, RabbitMQ, etc.) through a unified interface layer. The manager abstracts message queue-specific operations, allowing the same transaction processing logic to function across different message queue implementations. This provides both high performance through asynchronous messaging and broad adaptability to different system architectures.

Inventive Principle:
Principle #6Universality (Multi-functionality)

4Productivity

If a standardized deployment package is generated to improve deployment efficiency, then deployment speed is improved, but configuration flexibility may deteriorate

Engineering Contradiction:
Improvedeployment efficiencyVSAvoidconfiguration flexibility
Core Design Contradiction:
ProductivityVSAdaptability or versatility

Solution Approach 1:

The patent implements a dynamic configuration mechanism where the deployment package contains configurable parameters that can be adjusted after deployment. The transaction manager reads configuration from external sources (configuration files, environment variables, or database) rather than having hard-coded settings. This allows rapid deployment through standardized packages while maintaining flexibility to adapt configurations to different business scenarios and system environments.

Inventive Principle:
Principle #15Dynamics

Data Source

PatentUS11354303B2Distributed transaction processing method and system based on message queue and database
Publication Date: 2022.06.07 SHANGHAI ICEKREDIT INC
  • US11354303B2 patent drawing
  • US11354303B2 patent drawing

AI summary

A distributed transaction processing method and system based on a message queue and a database is provided. In the method, a component encapsulation server generates a target compressed package according to the obtained first configuration information of a business request server and the obtained second configuration information of a business execution server, and sends the target compressed package to the business request server and the business execution server, respectively, so that the business request server and the business execution server can decompress and configure the target compressed package to deploy a transaction processing component and a message transmission path. The system includes the component encapsulation server, the business request server and the business execution server. The business request server and the business execution server communicate with each other through the message queue. The component encapsulation server communicates with the business request server and the business execution server, respectively.