[jdev] Offline messages XEPs interoperability (XEPs 0013 and XEP-0160)

Matthias Wimmer m at tthias.eu
Fri Feb 21 16:58:02 UTC 2014


Hi Sergey,


maybe its a bit hidden in XEP-0013. Support for this protocol gets
activated by the client by sending a service discovery request to a node
of "http://jabber.org/protocol/offline".
If the client does not support or not want to use the protocol, it just
does not send this service discovery request. (Section 2.2)

In section 3 it gets a bit clearer: a client not supporting XEP-0013
gets the "message flood" after it sends the <presence/>. Clients
supporting XEP-0013 will have sent the service discovery request before
sending the <presence/>. The server therefore knows that the client uses
the protocol and does not flood messages after receiving the <presence/>
element.

Therefore I think it is possible to support XEP-0013 and XEP-0160 in the
same server implementation. The server floods the messages by default,
but switches to XEP-0013 handling when the client requested it.

Especially a server "only supporting XEP-0013" still has to flood
messages, if the client does not support offline message retrieval. This
is because XEP-0013 requires message flooding in this case as well.


Hope that helps,

Matthias



El 2014-02-21 18:08:55, Sergey Dobrov escribió:
> Date: Fri, 21 Feb 2014 18:08:55 +0200
> From: Sergey Dobrov <binary at jrudevels.org>
> Subject: [jdev] Offline messages XEPs interoperability (XEPs 0013 and
>  XEP-0160)
> To: jdev at jabber.org
> User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101
>  Thunderbird/24.2.0
> X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4
> 
> hey folks,
> 
> for now we have two different XEPs that allowing xmpp-servers to
> store messages that being sent while client was not available. XEP
> 0013 says that it's not very nice to flood all the messages on the
> client when it's becoming available, rather it advices to provide a
> way to discover such messages and query the necessary ones (and it's
> becoming something like inbox. the implementation is not the best to
> me, but it still nice), the XEP-0160 vice-versa says that we need to
> send all the messages when client has became available. And there is
> a good reason for that again: that way clients don't need any extra
> support of the offline storage.
> 
> Ok, we've seen that both XEPs cover some good usecase. But how to
> combine them? Can the xmpp server support both of them? I don't see
> a way for it to do that: if it supports 160 it needs to send all the
> messages immediately on client's presence but according to 13 it
> can't do that and I don't see any possibility for server to know
> which behaviour is the best for the client.
> 
> If server will support only 13, a big number of clients won't be
> able to obtain offline messages, but the 13 is still pretty nice to
> me (I just would want to add some more queries compatibility or even
> maybe combine it with MAM?). So, according to all these words above,
> what's the best way to me to implement such an inbox offline storage
> of messages?
> 
> Thanks.
> 
> _______________________________________________
> JDev mailing list
> Info: http://mail.jabber.org/mailman/listinfo/jdev
> Unsubscribe: JDev-unsubscribe at jabber.org
> _______________________________________________

-- 
Matthias Wimmer
Contact details:     http://matthias.wimmer.tel/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/x-pkcs7-signature
Size: 3941 bytes
Desc: not available
URL: <http://mail.jabber.org/pipermail/jdev/attachments/20140221/b572496a/attachment.bin>


More information about the JDev mailing list