Lock-Free Database Object Chains Using Atomic Pointer Updates

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Existing database systems face significant performance penalties due to processes having to wait for locks when multiple processes attempt to modify a shared cache's LRU chain for evicting or inserting database objects, leading to inefficiencies in database operations.

Innovation Solution

Implementing atomic operations, such as compare-and-swap (CAS), to manage database object chains without locking, allowing concurrent modifications by multiple processes through techniques like using eviction status flags and atomic operations to read and update chain pointers, ensuring consistency and integrity.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Reliability

If traditional locking mechanisms are used to manage the LRU chain, then data consistency is maintained, but system performance deteriorates due to process waiting and idle time

Engineering Contradiction:
Improvedata consistencyVSAvoidsystem performance
Core Design Contradiction:
ReliabilityVSProductivity

Solution Approach 1:

The patent extracts the locking mechanism from the chain management system and replaces it with atomic operations. Specifically, it uses compare-and-swap (CAS) operations on version numbers associated with each chain node, allowing concurrent access without traditional locks. This extraction eliminates the bottleneck while maintaining consistency through optimistic concurrency control.

Inventive Principle:
Principle #2Taking out (Extraction)

Solution Approach 2:

The patent changes the state management approach by introducing version numbers as a parameter for each chain node. Instead of using lock states, each node has a version number that is incremented atomically during CAS operations. This parameter change enables multiple processes to read and validate chain state simultaneously without blocking each other.

Inventive Principle:
Principle #35Parameter changes

2Productivity

If atomic operations are used to enable concurrent access, then system performance improves, but the complexity of managing chain consistency increases

Engineering Contradiction:
Improveconcurrent processing capabilityVSAvoidchain management complexity
Core Design Contradiction:
ProductivityVSDevice complexity

Solution Approach 1:

The patent segments the chain into independent nodes, each with its own version number. This segmentation allows CAS operations to be performed on individual nodes without affecting the entire chain, reducing the scope of consistency management. Each node can be independently validated and updated, simplifying the overall complexity compared to managing the entire chain as a single unit.

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

The patent introduces version numbers as intermediaries between the CAS operation and the actual chain data. The version number acts as a mediator that validates the current state before allowing modification, eliminating the need for complex locking protocols while maintaining consistency. This intermediary simplifies the interaction model for concurrent processes.

Inventive Principle:
Principle #24Intermediary (Mediator)

3Loss of time

If multiple processes manipulate the chain simultaneously, then idle time is reduced, but the risk of race conditions and inconsistent states increases

Engineering Contradiction:
Improveprocess idle timeVSAvoidchain state consistency
Core Design Contradiction:
Loss of timeVSReliability

Solution Approach 1:

The patent performs preliminary validation by reading the version number of each chain node before attempting modification. This preliminary action allows processes to validate the current state without blocking others, and only proceed with CAS operations if the state has not changed. This pre-validation approach enables simultaneous reads while preventing race conditions during writes.

Inventive Principle:
Principle #10Preliminary action

Solution Approach 2:

The patent implements feedback through the version number mechanism, where each CAS operation checks the current version number and increments it upon successful modification. This feedback loop provides real-time information about the chain state to all concurrent processes, allowing them to detect and handle conflicts without traditional locking. The version number serves as continuous feedback about the current state.

Inventive Principle:
Principle #23Feedback

Data Source

PatentUS20260064663A1Mechanisms for maintaining chains without locks
Publication Date: 2026.03.05 SALESFORCE INC
  • US20260064663A1 patent drawing
  • US20260064663A1 patent drawing
  • US20260064663A1 patent drawing

AI summary

Techniques are disclosed that relate to manipulating a chain of database objects without locking the chain. A computer system may maintain a chain that orders a set of database objects stored in a cache of the computer system. The computer system may receive a set of requests to perform database transactions. Based on those received set of requests, the computer system may determine to perform a plurality of chain operations that involve modifying the chain. The computer system may perform two or more of the plurality of chain operations at least partially in parallel using a set of atomic operations without acquiring a lock on the chain.