Simple multi segment write ahead log. Writes two type of files files *.index and *.store. Configurable maximum index and store file sizes.
Files stucuture:
- Index record structure: [recordID (8 bytes)][recordOffset (8 bytes)]
- Store record structure: [size (8 bytes)][data (variable bytes)]
wl, _ := wal.New(".", nil)
offset, _ := wl.Append(data)
data, _ := wl.Read(offset)
wl.Close()