[asterisk-dev] [Code Review] 2456: Pimp My SIP: Add SUBSCRIBE/NOTIFY support and MWI support

svnbot reviewboard at asterisk.org
Thu Apr 25 12:44:46 CDT 2013


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviewboard.asterisk.org/r/2456/
-----------------------------------------------------------

(Updated April 25, 2013, 12:44 p.m.)


Status
------

This change has been marked as submitted.


Review request for Asterisk Developers and Joshua Colp.


Changes
-------

Committed in revision 386532


Bugs: ASTERISK-21259 and ASTERISK-21260
    https://issues.asterisk.org/jira/browse/ASTERISK-21259
    https://issues.asterisk.org/jira/browse/ASTERISK-21260


Repository: Asterisk


Description
-------

This adds an API for SUBSCRIBE/NOTIFY support within chan_sip and provides an MWI module as the first user of the API.

The API allows for subscription handlers to register themselves as being able to handle specific event types and what sort of body types they accept. The API allows for subscription handlers to function either as subscribers or notifiers.

Subscription handlers are called into during certain milestones of a subscription. It is all documented in res_sip_pubsub.h

I added MWI support as a way of proving the concept of the API. MWI was both a good and a bad choice for this. MWI can be either solicited or unsolicited. Unsolicited MWI does not make use of the new API at all, but solicited MWI does. The solicited MWI is relatively straightforward as compared to unsolicited.


Diffs
-----

  /team/group/pimp_my_sip/include/asterisk/res_sip.h 386158 
  /team/group/pimp_my_sip/include/asterisk/res_sip_pubsub.h PRE-CREATION 
  /team/group/pimp_my_sip/res/res_sip/location.c 386158 
  /team/group/pimp_my_sip/res/res_sip/sip_configuration.c 386158 
  /team/group/pimp_my_sip/res/res_sip/sip_distributor.c 386158 
  /team/group/pimp_my_sip/res/res_sip_mwi.c PRE-CREATION 
  /team/group/pimp_my_sip/res/res_sip_pubsub.c PRE-CREATION 
  /team/group/pimp_my_sip/res/res_sip_pubsub.exports.in PRE-CREATION 

Diff: https://reviewboard.asterisk.org/r/2456/diff/


Testing
-------

I tested both solicited and unsolicited MWI.

I tested unsolicited MWI using a Polycom phone. I ensured that as voicemail state changed, the phone was updated with NOTIFYs that contained the proper message count.

I tested solicited MWI using both Jitsi and SIPp. I used Jitsi in order to ensure that the subscription was handled correctly and that MWI NOTIFYs were sent when the voicemail state changed. I used SIPp to test that unsubscribing from MWI notifications worked properly.


Thanks,

Mark Michelson

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-dev/attachments/20130425/fbd1a05f/attachment-0001.htm>


More information about the asterisk-dev mailing list