SIP Presence

来源:互联网 发布:天猫美工工作描述 编辑:程序博客网 时间:2024/04/19 12:49
网上Presence 文章也很多,不过很多只是稍微把Presnce介绍下,就开始一推的信令流程,或者又是一些比较抽象,概念化的描述,而对Presence业务本身所带来的场景和要实现这个业务所必须得条件也没有太好的描述。因为更多的就是SIP 或者加点XCAP的信令,但是具体SIP 或者XCAP 里所带有的用户信息描述的不够,没有啥对用户这个最终买单者的行为有分析。SIP 和XCAP 毕竟只是信令,一种手段来完成Presence这个过程。 自己看到,学习过,接触过的写下来。结合IMS IP Multimedia Concepts and Services 这本书来写。有引用。

  Presence is a dynamic profile of the user, which is visible to others and used to represent oneself,share information, and control service.Presence can be seen as a user's status as perceived by ohers and others' status as perceived by the user. Status may contain information such as personal adn device status.location or context,terminal capabilities,preferred contact method as well as services the user is willing to user to communicate with others, including voice,video,instant messageing as well as gaming.

  这么短的一句话,已经RCS 的绝大部分应用都概括了。但是这些应用都可以通过Presnce 这个业务来push给其他人知晓。 有点类似MSN ,QQ。 手机里的通讯簿不在是一个个数字,而是可以实时表现这些数字的用户的当前状态(例如,1.忙,不能接听电话,最好是发送短信。2.现在终端没有Vedio的能力,只能语音通话),地理信息(街旁,街景),签名吗,微博。 把这些都已经整合在一起,来把电话薄给多媒体化。

  Presence information is also personal:it is always linked to a particular person,. it shows the person initiating the communication whether the other person is avaliable and willing to communicate. On the other hand, presence information can be used to communicate to others when a person is able and willing to communicate as well as with whom and by what means. This will allow users to control their own communication more effectively.

   Presnce 背后所代表的都是每个具体的人物。 现在无论微博,FACEBOOK,Twitter, 用户都热衷把自己推送到网络上。Presence这边提供给了用户一个平台。也算接上潮流。。

用户通过IMS+RCS,建立了一个Peer<->Peer 这样用户之间的一个关联(所以SIP适合)。。。用户可以根据自己的喜好,对端用户的即时状态,来选择当前自己最喜欢的应用去推送,分享,交流。 与之前的GSM,PSTN 这种网络相比,用户是在被动的接受运营商所提供的服务。 现在换成用户在通过运营商提供的网络,用自己的方式来进行交流。。

   为了在网络中实现对用户在现实场景中行为的最大程度的还原(不知道这样形容对不对),让用户更好地感觉到通过虚拟世界的和真实世界之间的沟通的无缝,那就要求IMS,RCS 这边有各类不同的用户profile 来存储,收集用户的数据,并在这些数据的基础上做出尽量人性化的判断来满足用户对业务的需求。

  ( 那这样是否意味着用户的终端都必须又运营商来定制?这样的话,用户终端上的能力集才能更好地与运营商所提供的服务更匹配?)

  

   The Basic presence service as we know it today works with the basic idea of 'publish-receive' of presence information about humans.Operators have teh ability to fetch various infrastructure-related presence attributes, such as location and terminal availability from their communication networks.

   Presence is in essence two things,: it involves making my status avaiable to others and the statuses of others avalibale to me.   

   (这个过程通过PUBLISH-RECEIVE, SUBSCRIBER-NOTIYF 来完成这两个过程,前者主动推送自己的状态给网络服务器,后者通过订阅来从服务器收取前者的状态。)


Presence information include:

 1. Person and terminal availiability. (用户个人信息,例如用户名,别名,当前终端类型)

 2. Communication preferences.   (用户倾向的交流手段)

 3. Terminal capabilitites;  (终端的能力集,IMS 可能会有多个终端同时接入IMS 网络,手机,或者PC 上的软终端,两个分享一个用户号码。那挑选一个合适的终端来推送,收取Presence information 就对server来讲,比较重要)

 4. Current activity   (当前的活动,例如用户忙,已经处于通话中)

 5. Location  (当前用户位置。通过google map来直接定位用户所在地区

 6. Currently avaliable service. (当前用户,或者终端所支持的服务类型)


那么通过Presence 这些information的描述, 至少需要server来完成 以下事情:

1. 用户数据的存储。

2. 用户current 状态的维护与管理。

3. 用户订阅关系的建立于维护。

4. 用户黑白名单的维护与管理。用户当前的policy的维护与管理。

5. ....


OMA 的Presence Architecture 里定义了以下几个逻辑体:

1.Presence Server - an IMS applicaiton server that manager presence information uploaded by presence sources and handles presence subsription requests.

2.Resource List Server - an IMS application server that acepts and manages subscription to presence lists, which enables a watcher application to subscriber to the presence information of multiple presentities using a single subscription transaction.

3. XML Document Management Servers-application server that store presence server related data.

    Four different ASes:

            a. Presence XDMS -- a server that contains rules for presence information subscriptions and rules for presence information publication.

            b. RLS XDMS -- a server that contains user's presence buddylist)

            c. Presence Content XDMS -- a server that managers media files for the Presence Service)

            d. Shared XDMS -- a Server which can be reused by multiple different application servers).

4. Content Server- functional entity that is capable of managing MIME objects for Presence, allowing the presence sources or the Presence Server to store objects.


RLS server 和PS server 是为了实现Presence 业务的主要的Server, RLS Server来管理client 对于BUDDY LIST 的订阅。

PS 管理每个用户的状态,并且处理RLS 向PS 发送的订阅请求。

RLS Server, 因为一个UE的buddy list (好友列表) 中有多个用户,那么对于这每一个用户的Presence 状态, RLS 向PS 订阅(Subscriber) 每个用户的状态,这样RLS 收集到这个buddy list 中每个用户状态之后,再向UE返回NOTIFY(返回所有的用户状态).


而XDML Server 存储了一些Rule,比如黑白名单,BUDDY LIST 里对应的用户信息,MIME的存储信息(PS 将MIME 信息取到后回给UE, UE 然后去Content Server下载?)


5.Presence source - an entity that provides presence information to a presence service. The presence source can be located in a user's UE or within a network entity.

6.Presnece watcher - an entity that requests presence information about resources(pre-sentities).

7.Watcher agent - is an entity that controls the Watcher's Presence Service use in the Watcher domain.

8.Watcher Information Subscriber -is an entity that requests Watcher Information about a presentity from the Presence Service.


在Presence或者即时消息的模型里, 有这样一个模型,称为principal。 PRINCIPALS是人,团体,与/或系统之外的“现实世界”中的软件。每个PRINCIPAL在Presence 业务中 可以同时作为 Presentity 或者Watcher 存在,或者单独具有Presentity和Watcher中一方。

对于Presentity 来讲, 他把自己的在线状态,或者签名,头像通过PUSH 来推送出来。(PS XDMS 中会存储一些用户的基本信息,例如default的用户头像,在用户离线的时候,也可以让WATCHER来得到)

对于WATCHER来讲,它需要完成:

1. 订阅 Presentity 。

     2. 接受RLS 发过来的buddy list 中各个Presentity的一些default信息。

     3. 接受Presentity 的目前的在线的信息。

     4. Watcher 也需要讲自己的信息推送给Presentity 知道。 虽然Presentity可能没有订阅Watcher的Presence。Watcher 推送给Presentity 的信息,是让Presentity来决定是否接受这个WACTHER 对自己的订阅。。。类似QQ加好友。对方可以拒绝。



Presence 业务主要通过两个SIP Method 来实现, PUBLISH 和 SUBSCRIBER/NOTIFY。

UE 与AP 之间的Ut 接口使用 HTTP。UE通过Ut接口来修改自己在Presence 上存放的数据。比如头像,黑白名单,用户的policy。

PUBLISH requests create soft state in the ESC.  This event soft state   has a defined lifetime and will expire after a negotiated amount of   time, requiring the publication to be refreshed by subsequent PUBLISH   requests.  There may also be event hard state provisioned for each   resource for a particular event package.  This event state represents   the resource state that is present at all times, and does not expire.   The ESC may use event hard state in the absence of, or in addition
在这个描述中, Presentity推送给PS 的是软状态,是有时间限制的。那么对应的的硬状态,不受时间限制,例如用户的名字,用户额手机号码,或者用户手机所支持的业务能力集合。
原创粉丝点击