/plushcap/analysis/planetscale/the-mysql-adaptive-hash-index

The MySQL adaptive hash index

What's this blog post about?

The MySQL Adaptive Hash Index (AHI) is an optimization technique that improves the performance of B-tree lookups in relational databases, particularly when using the InnoDB storage engine. ABI works by creating a hash table in memory for frequently accessed values or value prefixes from a B-tree index, allowing faster direct lookups compared to traversing the B-tree structure. The ABI adapts its usage based on workload characteristics and can be enabled or disabled via configuration settings. In testing scenarios with large datasets and different query patterns, the ABI has shown performance improvements ranging from 16% to 20%.

Company
PlanetScale

Date published
April 24, 2024

Author(s)
Benjamin Dicken

Word count
2240

Hacker News points
None found.

Language
English


By Matt Makai. 2021-2024.