Database efficiency improvements
Some tweaks to the DB schema to improve efficiency:
- Only keep status rows for messages that are visible - this saves space and avoids the need to join the groupVisibilities table when selecting messages to offer or send
- Use adjacent columns for the composite primary key on the settings table
This MR depends on !101 (merged).