3 ms·
A mutable approach requires a write ahead log meaning you have to copy the data twice on every write which seems worse.
by vlovich123 3y ago
A mutable approach requires a write ahead log meaning you have to copy the data twice on every write which seems worse.
- hyc_symas 3y agoThere's an obvious tradeoff. With a 4K page size, the breakeven point is around 768 bytes per record. For larger records, the WAL approach is less efficient than LMDB. For smaller records, the WAL is more efficient in terms of write amplification. All thoroughly explored here http://www.lmdb.tech/bench/ondisk/ http://www.lmdb.tech/bench/ondisk/
- vajrabum 3y agoIn a well designed database system (hardware!) you aren't going to use the same CPU, disk or controller to write the log and the data structure. So the performance penalty if any is going to be low.
- loeg 3y agoNow you’re paying for double the hardware.
- vlovich123 3y agoLow but non 0 and you’re still duplicating the values written to disk. So your SSD lifetime is decreased and this is effectively a RAID0 layout which means data loss is risky too.
- iambvk 3y agoIt is: two writes for write ahead log vs. log-n (tree-height) writes for CoW