Convert from BoltDB to Maildir storage for emails

This commit is contained in:
2018-06-26 03:08:51 +01:00
parent d25ed6c1bd
commit a3c2508160
19 changed files with 869 additions and 175 deletions

View File

@@ -40,19 +40,9 @@ following, though:
* `Admin`
* `Wildcard`
* `PasswordHash`
* `Message`
* `ID`
* `Username`
* `Mailbox`
* `Header`
* `Body`
I don't seem to be able to get accounts for a list of usernames very easily, or
indexed-ly.
The message body is being stored inefficiently (json []byte, so base64-encoded)
Message username and mailbox are indexed, but is that good enough? Perhaps we
should have a bucket per mailbox or something?
TODO: rewrite this (and the code) to make Maildir into a thing
Messages are stored in a traditional Maildir structure structure following a
`<home>/mailboxes/<domain>/<username>` hierarchy.