From 9d1dd87a79929d2d82b264a4163b745fd3c340e9 Mon Sep 17 00:00:00 2001 From: Ben Johnson <benbjohnson@yahoo.com> Date: Fri, 27 Mar 2015 15:27:32 -0600 Subject: [PATCH 1/2] README Document use of free pages and page reclamation works. --- README.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/README.md b/README.md index 18ba570..691f9f9 100644 --- a/README.md +++ b/README.md @@ -550,6 +550,12 @@ Here are a few things to note when evaluating and using Bolt: However, this is expected and the OS will release memory as needed. Bolt can handle databases much larger than the available physical RAM. +* Because of the way pages are laid out on disk, Bolt cannot truncate data files + and return free pages back to the disk. Instead, Bolt maintains a free list + of unused pages within its data file. These free pages can be reused by later + transactions. This works well for many use cases as databases generally tend + to grow. However, it's important to note that deleting large chunks of data + will not allow you to reclaim that space on disk. ## Other Projects Using Bolt From a8ee2caab13f381bcdb552d5f95f89e03d204d8f Mon Sep 17 00:00:00 2001 From: Ben Johnson <benbjohnson@yahoo.com> Date: Fri, 27 Mar 2015 16:13:55 -0600 Subject: [PATCH 2/2] Add link to page reclamation comment. --- README.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/README.md b/README.md index 691f9f9..5b0a253 100644 --- a/README.md +++ b/README.md @@ -557,6 +557,11 @@ Here are a few things to note when evaluating and using Bolt: to grow. However, it's important to note that deleting large chunks of data will not allow you to reclaim that space on disk. + For more information on page allocation, [see this comment][page-allocation]. + +[page-allocation]: https://github.com/boltdb/bolt/issues/308#issuecomment-74811638 + + ## Other Projects Using Bolt Below is a list of public, open source projects that use Bolt: