jdev - 2021-10-20


  1. Zash

    In pubsub, is there a difference between pubsub#max_items=0 and pubsub#persist_items=false ?

  2. edhelas

    its been 30sec, I'm still thinking, and I don't have an answer yet :D

  3. flow

    Zash, probably not. but I think as soon as max_items > 0, then persist_items is of interest

  4. Zash

    what does max_items do if persist = false?

  5. flow

    under that assumption that persistence here means "store items in persitent storage", then max_items limits the number of items in volatile memory?

  6. Zash

    I'm under the impression that 'max_items' limit the number of items in _persistent_ storage

  7. flow

    the field labes gives the impression, yes

  8. flow

    even though, persist could mean here either on persistent storage or in volatile memory

  9. Zash

    isn't that an implementation detail in any case?

  10. Zash

    or internal something something

  11. flow

    define "that"?

  12. Zash

    "persistent storage" vs "volatile"

  13. Zash

    Why does that matter to a network protocol?

  14. flow

    In any case, I believe the description of pubsub#max_items "Max # of items to persist.…" to be ambiguous

  15. flow

    well it sure does matter to the user if his items are permanently stored or in volatile memory

  16. flow

    Zash, a pubsub implementation may not implement a persitent storage backend for its items (like prosody at the beginning). In that case, I'd say that the implementation can not allow persist_items=true

  17. flow

    However, an pubsub implementation may implement persitent storage, but also allows a node to be configured so that its items are only stored in volatile memory (perist_items=false)

  18. Zash

    Last time my understanding changed to be that persist_items=false means that events are broadcast and then *poof* gone

  19. flow

    Maybe, as I said, I beleive the specification to be ambiguous here. And a quick search of persist_items in xep60 did not clarify this for me

  20. jonas’

    just xep0060 things

  21. Zash

    indeed

  22. jonas’

    though the true xep0060 experience would've been if a `persist_nonvolatile` setting popped up which nobody had seen before which switches between the three behaviours

  23. jonas’

    (of course, persist_items=false and persist_nonvolatile=true would be undefined)

  24. Zash

    I've considered a way to configure which internal API to use