Journalling daemon - Allows multiple connections - The data from multiple connections is bundled into large writes to the journal - The journal files have a fixed maximum size. - Writes past the end of the journal cause a system-wide sync and writing starts over at the start of the journal. Design Decisions: - Use 64-bit CRC as block check code: - MD4 is faster (!) than even a hand-tuned CRC on P2/P3/Celeron CPUs due to its use of unrolled math operations instead of a per-byte table lookup which causes CPU serialization. - MD4 is a longer check code, which theoretically makes collisions less likely. - However, a CRC is designed such that all N-1 bit and shorter errors are guaranteed to be detected, whereas cryptographic hash have no such guarantee. - Include stream identifier meta-data with the stream - Delay committing transactions for a fraction of a second - Committing a transaction takes much longer than just writing data. - The cost of committing one transaction cannot be reduced. - The cost of committing N transactions can be reduced to that of committing one transaction by doing all the commits simultaneously. - If multiple connections are active, it is likely that one of the other connections will complete its data after the first one completes. - By waiting a fraction of a second, the first commit is delayed slightly, but the cost of that commit may be amortized by other commits happening simultaneously. - Uniform length-prefixed string format - Reduces complexity of file formats and protocols, compared to using multiple string formats, thereby reducing the complexity of the required code. - Include incremental global record number in each record - On wrap-around, this protects against older records being considered as valid after newer ones.