[Asterisk-code-review] res_pjsip_session: Add custom parameter support. (asterisk[master])

Alexei Gradinari asteriskteam at digium.com
Mon Jul 25 17:24:56 CDT 2022


Attention is currently required from: N A, Joshua Colp, George Joseph.
Alexei Gradinari has posted comments on this change. ( https://gerrit.asterisk.org/c/asterisk/+/18830 )

Change subject: res_pjsip_session: Add custom parameter support.
......................................................................


Patch Set 1:

(1 comment)

File doc/CHANGES-staging/res_pjsip_session_params.txt:

https://gerrit.asterisk.org/c/asterisk/+/18830/comment/a73b50b2_ee257f98 
PS1, Line 5: SIPURIPARAMETERS variable on a channel
I thought that in PJSIP we are moving away from using channel variables in favor of functions.

1. The name SIPURIPARAMETERS does not explain that asterisk adds the URI parameters only into From header. What if needed to add into To header?

2. I think that it would be more correct to do this through a function like PJSIP_HEADER
For example:
PJSIP_HEADER_URI_PARAMETER(header_name,action,name)
where action could be 'read', 'add', 'update' or 'remove'.

Examples:

; to get isup-oli parameter
exten => 1,1,Set(isup_oli=${PJSIP_HEADER_URI_PARAMETER(From,read,isup-oli)})

; to set isup-oli parameter
exten => 1,1,Set(PJSIP_HEADER_URI_PARAMETER(From,set,isup-oli)=1234567)



-- 
To view, visit https://gerrit.asterisk.org/c/asterisk/+/18830
To unsubscribe, or for help writing mail filters, visit https://gerrit.asterisk.org/settings

Gerrit-Project: asterisk
Gerrit-Branch: master
Gerrit-Change-Id: Ifb1bc3c512ad5f6faeaebd7817f004a2ecbd6428
Gerrit-Change-Number: 18830
Gerrit-PatchSet: 1
Gerrit-Owner: N A <mail at interlinked.x10host.com>
Gerrit-Reviewer: Friendly Automation
Gerrit-Reviewer: George Joseph <gjoseph at digium.com>
Gerrit-Reviewer: Joshua Colp <jcolp at sangoma.com>
Gerrit-Reviewer: Sean Bright <sean at seanbright.com>
Gerrit-CC: Alexei Gradinari <alex2grad at gmail.com>
Gerrit-Attention: N A <mail at interlinked.x10host.com>
Gerrit-Attention: Joshua Colp <jcolp at sangoma.com>
Gerrit-Attention: George Joseph <gjoseph at digium.com>
Gerrit-Comment-Date: Mon, 25 Jul 2022 22:24:56 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Gerrit-MessageType: comment
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20220725/aad76eeb/attachment.html>


More information about the asterisk-code-review mailing list