6 Commits
Author SHA1 Message Date
Matthew McNeelyandGitHub 56b2d31d75 chore: update README.md with correct links and badges (#2239)
**Description**

Updated links

Closes #2238
2025-12-10 22:11:18 +00:00
Ryan Fox-TylerandGitHub 94498ea84c chore: align repo conventions (#2158) 2025-02-05 17:00:32 -05:00
Aman MangalandGitHub bbd4b3f95c chore: remove dependency on io/ioutil (#1879)
we still have a couple of places where we are using io/ioutil.
2023-02-21 08:06:07 +05:30
Manish R JainandGitHub 82ff532103 feat(info): Add a flag to parse and print DISCARD file (#1662) 2021-02-04 18:38:20 -08:00
Naman JainandGitHub 02b6edbbdb test(wal): add test for stream-writer with jemalloc enabled and discard stats (#1557) 2020-10-15 14:54:37 +05:30
Manish R JainandGitHub 4ed8fbdc02 [BREAKING]: Change how Badger handles WAL (#1555)
This PR significantly improves Badger's disk usage behavior.

Breaking: This PR increases the magic version from 7 to 8. So, no older Badger directories would work with this change.

With this PR, we no longer use value log as write-ahead log. Instead, each MemTable has its own WAL. Value logs now only write values which are greater than ValueThreshold, while MemTable WAL only writes smaller values and value pointers.

On a crash and restart, the MemTable WALs are replayed to apply updates to Skiplist. When MemTables are flushed to L0, the corresponding WALs are deleted.

This PR makes big changes to how value log GC works:
- Discard stats are now stored in a separate file, instead of within the LSM tree.
- GC only picks up value logs based off discard stats.
- GC no longer does sampling, it uses discard stats to inform when a value log needs to be GCed.
- Value log would now no longer grow indefinitely, because of the shift to MemTable WAL.
- Removed the `badger gc` tool.
- Value Log Head pointer tracking is removed.
- Only the last value log file is replayed on every start, and truncated as necessary.

This PR also makes a bunch of other changes:
- Removes ValueLogLoadingMode (always uses mmap now).
- Removes TableLoadingMode (always uses mmap now).
- Removes Truncate option.
- Removes KeepL0InMemory option.
2020-10-06 18:41:41 -07:00