[Asterisk-code-review] res pjsip exten state: Create PUBLISH messages. (asterisk[master])

Richard Mudgett asteriskteam at digium.com
Fri Apr 29 14:55:01 CDT 2016


Hello Anonymous Coward #1000019, Joshua Colp,

I'd like you to reexamine a change.  Please visit

    https://gerrit.asterisk.org/2733

to look at the new patch set (#2).

Change subject: res_pjsip_exten_state: Create PUBLISH messages.
......................................................................

res_pjsip_exten_state: Create PUBLISH messages.

Create PUBLISH messages to update a third party when an extension state
changes because of either a device or presence state change.

A configuration example:

[exten-state-publisher]
type=outbound-publish
server_uri=sip:instance1 at 172.16.10.2
event=presence
; Optional regex for context filtering, if specified only extension state
; for contexts matching the regex will cause a PUBLISH to be sent.
@context=^users
; Optional regex for extension filtering, if specified only extension
; state for extensions matching the regex will cause a PUBLISH to be sent.
@exten=^[0-9]*
; Required body type for the PUBLISH message.
;
; Supported values are:
; application/pidf+xml
; application/xpidf+xml
; application/cpim-pidf+xml
; application/dialog-info+xml (Planned support but not yet)
@body=application/pidf+xml

The '@' extended variables are used because the implementation can't
extend the outbound publish type as it is provided by the outbound publish
module.  That means you either have to use extended variables, or
implement some sort of custom extended variable thing in the outbound
publish module.  Another option would be to refactor that stuff to have an
option which specifies the use of an alternate implementation's
configuration and then have that passed to the implementation.  JColp
opted for the extended variables method originally.

ASTERISK-25972 #close

Change-Id: Ic0dab4022f5cf59302129483ed38398764ee3cca
---
M include/asterisk/res_pjsip_outbound_publish.h
M res/res_pjsip_exten_state.c
M res/res_pjsip_outbound_publish.c
3 files changed, 215 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/33/2733/2
-- 
To view, visit https://gerrit.asterisk.org/2733
To unsubscribe, visit https://gerrit.asterisk.org/settings

Gerrit-MessageType: newpatchset
Gerrit-Change-Id: Ic0dab4022f5cf59302129483ed38398764ee3cca
Gerrit-PatchSet: 2
Gerrit-Project: asterisk
Gerrit-Branch: master
Gerrit-Owner: Richard Mudgett <rmudgett at digium.com>
Gerrit-Reviewer: Anonymous Coward #1000019
Gerrit-Reviewer: George Joseph <gjoseph at digium.com>
Gerrit-Reviewer: Joshua Colp <jcolp at digium.com>
Gerrit-Reviewer: Richard Mudgett <rmudgett at digium.com>



More information about the asterisk-code-review mailing list