Answer
Have the server assign a sequence number per conversation (or a time-ordered id) when it stores each message, not trust client clocks, which drift. Clients sort by that number, and a gap tells them a message is missing and should be fetched.
Realtime · Flashcard
Have the server assign a sequence number per conversation (or a time-ordered id) when it stores each message, not trust client clocks, which drift. Clients sort by that number, and a gap tells them a message is missing and should be fetched.