On 22/02/2023 14.14, Marvin W wrote:
Hi Flow,
Hi Marvin,
As it stands today, every message ideally has no more than two IDs:
That is where we already think different. The more archives messages are contained in, the higher the chances are that they are preserved and recoverable. Which is usually a good thing.
So groupchat message are ideally in the sending users MAM archive, in the archive of the groupchat (MUC/MIX) and in the receiving users archive. Therefore, they could have three <stanza-id/> elements when arriving at their destination.
The only reason why we need the second ID is that archives can't be sure that all messages they will store have a globally unique id assigned by their senders, otherwise the archive could just have used the sender's id.
Its fragile, at best, to build an archive that depends on external provided IDs for its content.
As a client developer, these are the only two IDs I'll store about incoming (and outgoing, though I will only learn the archive id later) messages. Even if you add a ton of other stanza-id's I'll just ignore them. And that's exactly what we would want developers to do to ensure they do it right. So the question is not to infer the by-attribute (because there is no by-attribute in my local store).
Even in your design, you need to know how to select the stanza-id you will store in your local store based on the 'by' attribute's value.
The question is only which of the two id's I use for what purpose. For MAM or reflection matching, it's obvious that the archive id or the sender id is to be used, respectively. And for message referencing, it depends on the message type (groupchats use archive id, direct chats use sender id).
That is where, I believe, we are on the same page. It's not rocket science. The hard part, which is maybe already solved, is, if the MUC(/MIX) stanza-id by attribute is [email protected] or muc.example.org. But that is probably for MAM to specify?
Then it is easy: If you talk over a MUC you use the <stanza-id/> that was added by the MUC. Same for MIX. And in 1:1 chats you use the senders <origin-id/>.
I think the only thing we really are not on the same page is if a reference should be fully qualified, i.e., the tuple of (id, by), or not. And I would prefer explicit over implicit here.
- Flow _______________________________________________ Standards mailing list Info: https://mail.jabber.org/mailman/listinfo/standards Unsubscribe: [email protected] _______________________________________________
