Log Structured InnoDB
For a while now I’ve been thinking that the way InnoDB handles transactions for all in-memory databases is flat out broken.
The vast majority of web applications using InnoDB are running the entire database out of memory.
With a 8-32GB database it only takes 1-3 minutes to write the whole image to disk.
If InnoDB were smart it would just enable a log-structured mode where it would continually read data from memory and write it to disk. The write ahead log would work but there would be no fuzzy checkpointing. In essence there would just be ONE continual checkpoint of the whole database.
When the database crashes you just read the database from the last checkpoint and replay log entries from the write ahead log. Basically a normal recovery.