Chinaunix首页 | 论坛 | 博客
  • 博客访问: 698413
  • 博文数量: 112
  • 博客积分: 2486
  • 博客等级: 大尉
  • 技术积分: 1541
  • 用 户 组: 普通用户
  • 注册时间: 2009-12-14 18:30
文章分类

全部博文(112)

文章存档

2012年(5)

2011年(48)

2010年(26)

2009年(33)

我的朋友

分类: LINUX

2009-12-22 14:26:36

一 Typical DUM callflow is:
Client Side:
1. Call dum.makeInviteSession
2. Add SDP (if required)
3. dum.send to send invite.
4. onNewSession gets called on first response from server with status >
100.
5. onProvisional gets called if server responds with a 1xx response
(excluding 100)
6. onConnected gets called when server responds with a 2xx response.
ackConnection should then be called on the ClientInviteSession.
...
7. To disconnect: on the ClientInviteSession - call cis.send(cis.end()) -
this will send the BYE request.
8. onTerminated is then called after receiving the 200 response to the BYE.

Server Side
1. onNewSession gets called when an inbound INVITE is received.
2. Server can then use ServerInviteSession to send provisional() - if
required.
3. Server uses ServerInviteSession to send accept() - adding any required
SDP. This sends the 200 response to the client.
...
4. onTerminated is called when client sends BYE. DUM sends the 200
response.

二 关于实例化DUM个数的问题

 在reSIProcate wiki资料中说"a single DUM can be shared by multiple UAs."就是多个UA(User Agent)可以共用一个DUM(Dialog Usage Manager,会话管理器)。
那为什么在reSIProcate代码中的resiprocate-1.5\resip\dum\test\BasicCall.cxx中用了两个DUM呢?如下:
SipStack stackUac;
DialogUsageManager* dumUac = new DialogUsageManager(stackUac);
SipStack stackUas;
DialogUsageManager* dumUas = new DialogUsageManager(stackUas);
两个SipStack,两个DUM。

这是因为该例子是用于实现本机呼叫本机,即本机上同时登陆两个用户,用不同的端口,这两个用户之间呼叫。
One DUM is recommended. BasicCall is setup so that it can call itself
(on a different port and stack instance) for demo/test purposes only.

三 BasicCall CallFlow




阅读(2831) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~