(MDBX) libraries released with the implementation of a high-performance compact embedded database of the key-value class, and the linked library (FPTA), which implements a table view of data with secondary and composite indexes on top of MDBX. Both libraries are distributed under approved licenses . All current operating systems and architectures are supported, as well as the Russian Elbrus 2000.
Historically, libmdbx is a deep reworking of theand surpasses its predecessor in reliability, feature set, and performance. Compared to LMDB, libmdbx places a lot of emphasis on code quality, API stability, testing, and automated checks. A utility for checking the integrity of the database structure is supplied with some recovery options.
Technologically libmdbx offers ACID, strict change serialization, and non-blocking reads with linear scaling across CPU cores. It supports auto-compactification, automatic database size control, and range query estimation. Since 2016, projects have been funded byand have been used in since 2017 .
For libmdbx, aoffered , as well as supported by enthusiasts for Rust, Haskell, Python, NodeJS, Ruby, Go, Nim. For libfpta, only the in the form of a C / C ++ header file is publicly available .
The main innovations, improvements and fixes added after the previous news from May 9:
- Provided the reproducible assemblies.
- Fixed a bug due to which, under a very rare set of circumstances, a loop / hang could occur during the commit of a transaction. The problem was identified by Positive Technologies specialists during internal testing of their own products.
- Tests have been improved and test scripts have been extended to check all reachable non-isomorphic states of the page tree and GC content inside the database.
- In the C ++ API corrected once “noexcept”, added the additional overload for method “cursor :: erase ()”, the implementation of the buffers by the use of “std :: string” to ensure alignment (actual for CLANG libstdc ++).
- Fixed in the dirty page spilling algorithm (selective eviction of modified database pages) that manifested itself in a rare unexpected error MDBX_PROBLEM when changing data in huge transactions.
- A phasing carried out with the addition of a number of checks to ensure stability in case of deliberate damage to the database.
- Fixed minor UndefinedBehaviorSanitizer and Coverity Scan issues.
- Fixed checking of outdated and already unused internal flag “P_DIRTY” in nested pages inside database images created by old versions of the library.
- In CMake scripts, the search for compiler components required for LTO (link-time optimization) has been improved.
- The maximum number of concurrent readers has been increased to 32,767.
- Improved performance when using Valgrind and AddressSanitizer.
- Fixed recursive use of SRW-lock on Windows when working in MDBX_NOTLS mode (without using thread local storage), fixed bootid generation in case of system time change, improved detection of WSL1 and WSL2, added the ability to open a database mounted using DrvFS.
- In total, more than 160 changes were made to 57 files, ~ 5000 lines added, ~ 2500 removed.
I would also like to thank theproject (Ethereum ecosystem) for their help in testing in extreme use . It is significant that in the five months since the release of libmdbx v0.10.0, with a database volume of 1-2 TB in each Erigon installation (used by 7% of Ethereum nodes), only three reports of database damage have been received, all were due to external reasons, and not software errors: in two cases, the cause was RAM failures, in the third, a data zeroing error in a specific storage subsystem configuration using BTRFS.