github cristianadrielbraun/gofer v0.7.0

latest releases: v0.26.0, chart-v0.1.13, v0.25.0...
one month ago

This release is about speed. I measured Gofer with a 200,000-message mailbox and with many people using it at once, and reworked the slow parts. Most actions that took close to a second on large mailboxes now take a few milliseconds.

Faster with large mailboxes

200,000-message mailbox 0.6.0 0.7.0
Open a message in the list 142 ms 6 ms
Unread filter 829 ms 1 ms
Mark as read 705 ms 1 ms
Check a folder for new mail 700 ms 0.3 ms
Search box, common word 1,426 ms 178 ms
First download of 20,000 messages 35 s 2.7 s
  • Message lists, unread counts, filters and conversations update only what changed instead of recounting the whole mailbox.
  • Downloading and saving mail is several times faster.

Faster with many people

  • With 32 people using Gofer at once, slow requests take 24 ms instead of 60 ms, and the server uses a third of the CPU.
  • Syncing skips folders that haven't changed, keeps mail server connections open, runs more accounts at once, and puts people's own actions first.
  • New mail shows up at once for everyone who has Gofer open, and live updates go only to the people they are about.

Lighter pages and storage

  • The inbox page went from about 1 MB to 360 KB. Scripts are minified, long menus are built only when opened, and fonts are served by Gofer itself instead of an outside service.
  • Stored messages are compressed, about 60% smaller on disk.

Fixes

  • Fixed drafts that could disappear while being saved.
  • Fixed saves that could fail with "database is locked".
  • Classic icons on contact cards in Express.

Before upgrading

  • Compressed messages: messages saved by 0.7.0 can't be read by 0.6.x. Going back needs your backup.
  • Older messages stay as they are and still read normally. To compress them too, run gofer storage compress (add --dry-run to see the savings first). It is safe while Gofer runs and can be stopped and resumed.
  • Memory: peak memory use is somewhat higher (about 185 MB instead of 147 MB in the multi-user test), mostly database pages the system can reclaim.
  • Building from source needs Go 1.27.1, and task generate needs network access once to download the script minifier.
  • The database gains new indexes and tables on first start. Nothing is converted, but first start on a large mailbox may take a moment. As always, back up your data directory first.

Gofer remains pre-1.0. I'm actively using and improving it, but please keep backups and test your setup before relying on it for anything critical.

Don't miss a new gofer release

NewReleases is sending notifications on new releases.