Get the latest tech news

Message order in Matrix: right now, we are deliberately inconsistent


ht now, we are deliberately inconsistentDecember 04, 2024 [Matrix, Tech] After lots of conversations with Element colleagues about message order in Matrix, and lots of surprises for me, I wanted to write down what I had learned before I forgot, and also write down some principles I think we should try to follow. A lot of this is just my half-formed opinions, and while I am very grateful to everyone who helped educate me about all of this, it in no way represents any kind of policy or consensus from Element or Matrix or anyone else :-) Finding messages If you're writing a Matrix client (e.g.

This seems unremarkable at first glance: the/sync response even contains a prev_batch token which we can use as the from query parameter to/messages so we can page back through messages to find older ones. So far, we've been assuming that if the homeserver just passes on messages to the client as soon as it receives them, this will result in a reasonably sensible order and an accurate reflection of the timeline. After I wrote the first draft of this post, some colleagues and I discussed it, and thought up some reasons why a "persistent sync order" or "linearised timeline" has problems we would need to solve.

Get the Android app

Or read this on Hacker News

Read more on:

Photo of matrix

matrix

Photo of Message order

Message order

Related news:

News photo

Encrypted Communications Service 'Matrix' Dismantled by the Police

News photo

Eurocops take down 'secure' criminal chat system known as Matrix

News photo

Police seize Matrix encrypted chat service after spying on criminals