XMPP only does this on the single server the room resides on and does not share this info with other participating servers except for the bare minimum needed to show the user's nick names.
I recommend you hosting your own Matrix home server and after joining a few rooms look at your database what kind of historical metadata ends up on your new server. It's honestly appalling from a privacy point of view.
Yes this is needed for room persistence across multiple servers, but IMHO that is a solution looking for a problem and IMHO also a highly over-engineered one.
Ferk@lemmy.ml 2 years ago
There's ongoing work to encrypt the metadata too. https://github.com/matrix-org/matrix-doc/pull/3414
Without this solution the transition to p2p would be much more complicated, would it not?