[OpenSIPS-Users] Presence aggregation
anca.vamanu at gmail.com
Sun Oct 30 20:50:09 CET 2011
On Sat, Oct 29, 2011 at 2:48 PM, Damien Sandras <dsandras at seconix.com>wrote:
> Hello everyone,
> When having multiple presence sources for a same SIP uri (e.g. different
> devices or when mix_dialog_presence is enabled), OpenSIPS puts the newest
> one on top. Consequently, most softphones display the most up to date
> information first.
> However, I wonder what is the exact behavior : does it change on presence
> refresh through PUBLISH requests, or only when a new and different XML body
> is published for a given tuple ?
> For example, imagine the following generic behavior :
> 1) At 10am, I publish a PIDF document with a given tuple. It is valid for
> 5 minutes.
> 2) At 10:04am, I publish another PIDF document with another tuple for the
> same presence URI. It is valid for 5 minutes.
> 3) At 10:05am, the first PUBLISH is refreshed for another 5 minutes.
> What will be the topmost state in the PIDF ? The one published at 10am and
> lastly refreshed, or the one published at 10:04am ?
> If this last one is not refreshed, I suppose it switches back to the 10am
> published state. Am I right ?
Yes, you are right. Basically the presence aggregation selects the pidfs
from database sorted in the order 'latest changed first', so you will
always have the latest changed on top.
As a small note - it doesn't actually matters if the tuple id is different,
but only if the Publish contains a SIP-If-Match header and if that Etag
matches an existing record or not. This is how it is decided if it is a new
publication for the same presentity or a refresh of an existing one.
> Thank you,
> Damien Sandras
> Users mailing list
> Users at lists.opensips.org
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Users