Bz-tree durability with copy-on-write checkpoints

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Existing database management systems face performance penalties due to random disk writes during durability requirements and struggle with maintaining consistency during concurrent transactions, especially in large databases with high write loads, leading to prolonged checkpointing operations and overhead.

Innovation Solution

The Bz-tree implementation supports durability and multi-version concurrency control (MVCC) using structurally consistent copy-on-write checkpoints, allowing concurrent transaction writing without keeping old versions, and utilizing a row-level write-ahead logging (WAL) system to reduce WAL traffic and improve checkpointing efficiency.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Reliability

If traditional checkpointing is used to ensure durability and consistency, then data integrity is maintained, but system performance deteriorates due to prolonged checkpointing operations and overhead

Engineering Contradiction:
Improvedata integrityVSAvoidsystem performance
Core Design Contradiction:
ReliabilityVSProductivity

Solution Approach 1:

The patent applies preliminary action by pre-allocating version slots within each B+-tree node and preparing the structure for multiple versions in advance. This eliminates the need for traditional checkpointing operations, as the system can directly write new versions to disk without prolonged checkpointing pauses, thus maintaining data integrity while improving system performance

Inventive Principle:
Principle #10Preliminary action

Solution Approach 2:

The patent extracts the checkpointing overhead from the critical transaction path by implementing versioned nodes that can be written directly to disk. The durability and consistency functions are separated from the main transaction flow, allowing transactions to commit without waiting for checkpoint completion, thereby resolving the performance-d integrity contradiction

Inventive Principle:
Principle #2Taking out (Extraction)

2Reliability

If old versions of data items are kept during concurrent transactions, then transaction isolation is maintained, but memory overhead increases

Engineering Contradiction:
Improvetransaction isolationVSAvoidmemory overhead
Core Design Contradiction:
ReliabilityVSQuantity of substance

Solution Approach 1:

The patent implements nested doll by embedding multiple versions of data items directly within the B+-tree node structure itself. Each node contains version slots that hold historical versions, eliminating the need for separate undo logs or version storage structures. This nested approach maintains transaction isolation through version availability while significantly reducing memory overhead compared to external version storage mechanisms

Inventive Principle:
Principle #7Nested doll (Nesting)

Solution Approach 2:

The B+-tree nodes serve multiple functions: they store current data versions, maintain historical versions for isolation, and provide the indexing structure. This multi-functionality eliminates the need for separate structures to maintain old versions, reducing overall memory overhead while preserving transaction isolation guarantees

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

3Reliability

If data is written to disk before being confirmed, then durability is improved, but random disk writes increase causing performance penalties

Engineering Contradiction:
ImprovedurabilityVSAvoidwrite performance
Core Design Contradiction:
ReliabilityVSProductivity

Solution Approach 1:

The patent merges multiple data writes into a single atomic B+-tree node write operation. Since entire nodes are written to disk together as atomic units, multiple logical writes are combined into one physical write operation. This maintains durability through atomic writes while eliminating the performance penalty of scattered random writes, as the node-level write can be more efficiently managed by the storage system

Inventive Principle:
Principle #5Merging (Combining)

4Reliability

If block-level checkpointing is used, then durability is ensured, but checkpointing efficiency decreases due to large checkpoint sizes

Engineering Contradiction:
ImprovedurabilityVSAvoidcheckpointing time
Core Design Contradiction:
ReliabilityVSLoss of time

Solution Approach 1:

The patent segments the checkpointing process into node-level operations rather than requiring full block-level checkpoints. Each B+-tree node is independently versioned and can be written to disk separately. This segmentation allows incremental durability enforcement without the overhead of large block-level checkpoints, significantly reducing checkpointing time while maintaining durability guarantees

Inventive Principle:
Principle #1Segmentation

Data Source

PatentUS10325030B2Durable multiversion B+-tree
Publication Date: 2019.06.18 SUPABASE INC
  • US10325030B2 patent drawing
  • US10325030B2 patent drawing
  • US10325030B2 patent drawing

AI summary

Embodiments of the systems and methods disclosed include a durable multiversion modification of B+-tree with full transaction semantics. In-memory and persistent page images are managed without a buffer manager. Instead, a non-leaf page downlink directly points either to in-memory or on-disk pages. In turn, the reduced amount of fetches per page access improves scalability on multi-core hardware platforms. Embodiments include structurally consistent copy-on-write checkpoints that enable using row-level write-ahead logs. In combination with in-memory undo log for multiversion concurrency control, the amount of persistent storage operations is significantly reduced.