jdev - 2023-09-30


  1. singpolyma

    If I do a full mam sync before i set presence to available I'm likely to get duplicate messages from offline delivery, yes?

  2. lovetox

    also if you do the mam sync after available

  3. lovetox

    just the duplicates come from mam then and not offline delivery

  4. lovetox

    was there no some way to disable offline delivery

  5. lovetox

    was there not some way to disable offline delivery

  6. lovetox

    i solved this by the realization that i need deduplication anyway

  7. lovetox

    even if you do everything perfect, as you dont know the mam id of messages you sent yourself, these will arrive as duplcates for sure

  8. singpolyma

    Well, if I do mam sync after I send presence I might miss messages I think, vut shouldn't get dupes. Depends what you use as your id to sync from i guess

  9. singpolyma

    > even if you do everything perfect, as you dont know the mam id of messages you sent yourself, these will arrive as duplcates for sure Only if you sync back that far

  10. singpolyma

    I'm mostly thinking about JMI and detecting calls

  11. singpolyma

    Which I can dedupe by id just need to be careful

  12. lovetox

    far? you send one message and go offline, when you come online you sync from a message you received, so you will immediately receive the one you sent last

  13. Zash

    Wasn't there some magic to get rid of offline messages in favor of MAM?

  14. lovetox

    > Well, if I do mam sync after I send presence I might miss messages I think no, why do you think that?

  15. Zash

    https://chat.modernxmpp.org/log/modernxmpp/2021-08-31#2021-08-31-8518a542bd283686 https://hg.prosody.im/trunk/rev/906ea5e1ec75 https://hg.prosody.im/trunk/rev/d66738eeb875

  16. singpolyma

    >> Well, if I do mam sync after I send presence I might miss messages I think > no, why do you think that? Because if I get a message live, mrm sync isn't done yet, then something goes wrong when I come back I may sync from that live message and miss the part of mam that wasn't done yet

  17. lovetox

    hm .. sounds like a really easy problem to solve

  18. lovetox

    dont accept mam-ids as sync point from live messages, while a sync is going on

  19. lovetox

    i mean how do you do this in a MUC? where you cant sync before presence?

  20. singpolyma

    So keep track of the mam id from live, but don't save it until sync is done? Hmm

  21. lovetox

    no i dont keep track of it, i simply ignore them

  22. Zash

    Who doesn't let you MUC MAM before presence?

  23. lovetox

    the last mam-id from the sync is the last message

  24. singpolyma

    So you only ever sync from the end of your last sync?

  25. lovetox

    yes

  26. singpolyma

    Won't you dupe all live messages from your last session that way?

  27. lovetox

    no you misunderstood me

  28. lovetox

    i ignore the mam-id of live messages *while* a sync is ongoing

  29. lovetox

    afterwards of course i dont ignore them

  30. lovetox

    and i mistunderstood your question, my last yes should have been a no :D

  31. singpolyma

    Ah ok. So if you crash/quit after mam sync but before another live after that you'll get a few dupes, but that's probably small

  32. lovetox

    hm not sure i understand the scenario, but yes the goal is, as long as you are not *in sync* with the archive, dont accept any mam-ids from other sources

  33. lovetox

    for me that worked ok for now, never had complaints, but in anyway you need deduplication

  34. lovetox

    > Ah ok. So if you crash/quit after mam sync but before another live if i crash after mam sync, i have the latest mam-id, if i come online again i sync from that, and will receive exactly the one live message

  35. lovetox

    singpolyma, you operate that sms gateway or?

  36. lovetox

    is this jmp.chat?

  37. lovetox

    i want to test that in Gajim, whats the address of this gateway?

  38. singpolyma

    The gateway is at xmpp:cheogram.com

  39. singpolyma

    If you want an account with a number for full testing I can get you one free no problem