News for hackers. Stuff that matters.
Re:An efficient ActivityPub Server, for small installs with ... by andrewgodwin on Thursday November 24, 2022 @02:36PM (#33735362)
Author here - it's just to reduce support surface area. I know I'll need PostgreSQL's full text indexing and GIN indexes for hashtags/search eventually, and I probably also want to use some of the upsert and other specialised queries, and it's easier to just target one DB I know is very capable.

For reference, when I say "small to medium", in my head that means "up to about 1,000 people right now".

Re:An efficient ActivityPub Server, for small installs with ... by UncleEntity on Thursday November 24, 2022 @03:58PM (#33736155)
I was poking into this a bit yesterday.

Is there any advantage to using a traditional db as opposed to a graph db since json-ld is just a text representation of graph nodes?

I was thinking the easiest path would be have the server deal with all the activityPub stuff and expose something like a graphQL interface for a bring your own client implementation. Of all the stuff they shoehorned graphQL into this seems like a valid fit, like they were made for each other.

Anyhoo, just my random thoughts…

Re:An efficient ActivityPub Server, for small installs with ... by manfre on Thursday November 24, 2022 @04:50PM (#33736613)
For better or worse, many servers are targeting Mastodon API compatibility to be able to leverage the existing clients. Adding GraphQL increases surface area without solving the bigger issue of creating the clients.
Re:An efficient ActivityPub Server, for small installs with ... by UncleEntity on Thursday November 24, 2022 @05:02PM (#33736727)
I didn’t get as far as looking into the mastodon API for clients but that makes perfect sense, I just assumed it was an overlay on the more general API.

Mostly I was thinking how one could implement something in the most efficient way and graph databases/graphQL were literally designed for this stuff.

Re:An efficient ActivityPub Server, for small installs with ... by actionfromafar on Thursday November 24, 2022 @07:53PM (#33737860)
That sounds like a very low number I would have never have guessed. Is Mastodon so heavy?
Re:An efficient ActivityPub Server, for small installs with ... by olliej on Friday November 25, 2022 @12:40AM (#33739601)
People were getting priced out of hosting an instance with "only" 10-20k users and the instance hosting services quote <= 4k users with the 4k end being >$US100/month. With the "low end" 1-200 user instances having 4 cores, 5tb of monthly bandwidth, etc.

The general sense I have got is that mastodon - the default software at least - is extremely resource heavy for relatively low user counts. My assumption/hope was that the bulk of this is that the server software hasn't ever really been under sufficient pressure to improve, and takahē seems to indicate that there's at least some room for improvement on the server side (i.e. performance problems aren't entirely protocol/architecture problems)

Re:An efficient ActivityPub Server, for small installs with ... by Tepix on Friday December 02, 2022 @03:21AM (#33828121)
SQLite has full text search and upsert.

GIN indexes sound cool - perhaps you can get away not using them however and instead support 2 DB backends?

If you want to accomodate "small" and not just medium, that would be great! ;-)