Mastodon is very resource heavy, I couldn't get it to run on a raspberry pi 3b. Pleroma is an alternative to mastodon that is very light on resources, I'd recommend that personally.
I think the main issue of Mastodon is that its search completely reliant on elasticsearch, while Pleroma tries to go by only with PostgreSQL FTS?
Even if SQLite JSON isn't sufficient it could be realized with string columns for now, and indeed SQLite is recommended by Library of Congress for archival storage and used by iPhone so I think it's a solid way to expand Pleroma even if native JSON is not sufficient.
If anyone wants to pay me to do this as open source I'd jump, contact in bio. I don't know Elixir yet but am motivated and have 15+ years of dev experience in all kinds of systems, and experience in the adjacent parts.
1. For anything where you are mentioned specifically, or where you're a follower, the toots gets distributed automatically.
2. For anything where the toot is marked public but you are not a follower or mentioned, your instance will only receive a toot if you've explicitly configured federation of the public feed with one or more instances that is reasonably well connected.
The former is "cheap" unless you follow lots of people. The latter is like sucking on a firehose, because you get pretty much everything. If you do, it matter relatively little how large your userbase is, because you're still processing nearly every public toot.