How does federation work (technically)?

Good evening,

I’ve begun looking into Mastodon and I think it is a great initiative and alternative to today’s siloed web!

I’m running an instance now and I’ve started following a few users on other instances. I understand the gist of how it works from seeing the “How it works” video on joinmastodon.org, but I’d like to understand it on a more technical level. When I follow users I see there are entries created in account in the database on my instance, and I see their message show up in my timeline. Are these messages pulled and stored in my instance db, or are they just fetched “real time” ? What if they delete their messages, are the deletes propagated to all other instances where there are followers? What if the instance is down?

I’d appreciate if someone can shed some more light on the nature of this!

You might want to start with

and read ActivityPub specification along with it.

Thanks, that just seems like an overview of what part of the spec it implements though. Guess I’ll go to the ActivityPub spec and maybe have a closer look at the source code.

ActivityPub is kind of transport protocol. It is not enought to implement mutually intelligible social networks.

Pleroma people suggest looking at their test suite at Pleroma / pleroma · GitLab to see differences among various implementations.