Multithreaded Transaction Engine Concurrency Control

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Existing event-driven systems, such as database systems, face challenges in efficiently managing concurrent execution of Event Condition Action (ECA) rules, leading to potential inconsistencies and reduced scalability due to inadequate concurrency control mechanisms.

Innovation Solution

The implementation of a multithreaded transaction execution system with fine-granular locking mechanisms and an optimistic concurrency control approach, allowing for synchronous and asynchronous execution of ECA rules while ensuring consistency and isolating concurrent transactions.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Productivity

If concurrent execution of ECA rules is enabled to improve scalability and reduce execution latencies, then productivity is improved, but inconsistencies and reliability issues may occur due to inadequate concurrency control

Engineering Contradiction:
Improvetransaction throughputVSAvoidtransaction consistency
Core Design Contradiction:
ProductivityVSReliability

Solution Approach 1:

The patent segments the concurrency control mechanism into fine-grained locks that can be independently acquired and released on different data items. This allows multiple transactions to proceed concurrently on different segments of data, improving throughput while maintaining consistency through localized locking rather than global locking.

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

The patent introduces an intermediary locking mechanism that mediates between concurrent transactions. The fine-grained locks act as intermediaries that coordinate access to shared resources, allowing transactions to proceed concurrently when no conflict exists while preventing inconsistencies when conflicts are detected.

Inventive Principle:
Principle #24Intermediary (Mediator)

2Reliability

If fine-granular locking mechanisms are implemented to ensure transaction consistency, then reliability is improved, but device complexity increases due to additional control structures

Engineering Contradiction:
Improvetransaction consistencyVSAvoidcontrol mechanism complexity
Core Design Contradiction:
ReliabilityVSDevice complexity

Solution Approach 1:

The patent applies local quality by implementing fine-grained locks that are specific to individual data items or small groups of data items rather than a single global lock. Each lock has a localized scope, allowing the system to maintain consistency where needed while avoiding unnecessary complexity in areas where concurrency is not required.

Inventive Principle:
Principle #3Local quality

3Productivity

If multithreaded execution is used to increase transaction throughput, then productivity is improved, but execution time management becomes more complex and may lead to race conditions

Engineering Contradiction:
Improvetransaction throughputVSAvoidthread management complexity
Core Design Contradiction:
ProductivityVSDevice complexity

Solution Approach 1:

The patent implements preliminary action by acquiring fine-grained locks before transactions access shared resources. This preliminary locking action prevents race conditions from occurring in the first place, rather than detecting and resolving them after they occur, simplifying the overall thread management complexity.

Inventive Principle:
Principle #10Preliminary action

Data Source

PatentUS10002161B2Multithreading and concurrency control for a rule-based transaction engine
Publication Date: 2018.06.19 SAP SE
  • US10002161B2 patent drawing
  • US10002161B2 patent drawing
  • US10002161B2 patent drawing

AI summary

The subject matter disclosed herein provides methods and apparatus, including computer program products for rules-based processing. In one aspect there is provided a method. The method may include, for example, evaluating rules to determine whether to enable or disable one or more actions in a ready set of actions. Moreover, the method may include scheduling the ready set of actions, each of which is scheduled for execution and executed, the execution of each of the ready set of actions using a separate, concurrent thread, the concurrency of the actions controlled using a control mechanism. Related systems, apparatus, methods, and/or articles are also described.