[OpenSIPS-Users] BYE processing and AVP

Bogdan-Andrei Iancu bogdan at voice-system.ro
Tue Nov 30 21:15:09 CET 2010


Hi Anton,

if you are looking for dialog- persistent variables, use the dialog 
module and the dialog variables:
       http://www.opensips.org/html/docs/modules/1.6.x/dialog.html
       http://www.opensips.org/html/docs/modules/1.6.x/dialog.html#id295169

Note that you need to create the dialog (at INVITE time) via 
"create_dialog()" function before start using the dialog variables.

Regards,
Bogdan

Anton Zagorskiy wrote:
>
> Ok, thanks!
>
>  
>
>  
>
>  
>
>  
>
> 2
>
>
> 	
>
>  
>
>  
>
> *From:* users-bounces at lists.opensips.org 
> [mailto:users-bounces at lists.opensips.org] *On Behalf Of *mayamatakeshi
> *Sent:* Tuesday, November 30, 2010 5:29 PM
> *To:* OpenSIPS users mailling list
> *Subject:* Re: [OpenSIPS-Users] BYE processing and AVP
>
>  
>
>  
>
> On Tue, Nov 30, 2010 at 11:19 PM, mayamatakeshi 
> <mayamatakeshi at gmail.com <mailto:mayamatakeshi at gmail.com>> wrote:
>
>  
>
> 2010/11/30 Anton Zagorskiy <a.zagorskiy at oyster-telecom.ru 
> <mailto:a.zagorskiy at oyster-telecom.ru>>
>
>      
>
>     Why BYE isn't a part of the transaction?
>
>
> From RFC3261:
>
> Specifically, a SIP transaction consists of a single request and any responses to
>    that request, which include zero or more provisional responses and
>    one or more final responses.
>
> But when opensips docs say transaction, it is also implying that you 
> are using module tm (if you don't use tm functions, then you are doing 
> stateless processing and no AVP will be saved). 
>
>
> For completeness,
> the BYE is part of the dialog established by the INVITE transaction 
> that ended when "200 OK" was received. But the BYE itself starts 
> another transaction.
> So, the AVPs you set in the processing of the INVITE will be available 
> (as long as you use module tm) when your process responses for that 
> INVITE (180, 183, 200 etc), but not when you are handling other 
> requests in the dialog.
>  
>
>      
>
>
>         WBR, Anton Zagorskiy
>         VoIP Developer, Oyster Telecom
>         Phone.: +7 812 601-0666
>         Fax: +7 812 601-0593
>
>         a.zagorskiy at oyster-telecom.ru
>         <mailto:a.zagorskiy at oyster-telecom.ru>
>
>         www.oyster-telecom.ru <http://www.oyster-telecom.ru>
>
>
>         From: users-bounces at lists.opensips.org
>         <mailto:users-bounces at lists.opensips.org>
>         [mailto:users-bounces at lists.opensips.org
>         <mailto:users-bounces at lists.opensips.org>] On Behalf Of
>         mayamatakeshi
>         Sent: Tuesday, November 30, 2010 4:13 PM
>         To: OpenSIPS users mailling list
>         Subject: Re: [OpenSIPS-Users] BYE processing and AVP
>
>
>
>         On Tue, Nov 30, 2010 at 10:07 PM, Anton Zagorskiy
>         <a.zagorskiy at oyster-telecom.ru
>         <mailto:a.zagorskiy at oyster-telecom.ru>> wrote:
>         Hello.
>
>         During INVITE processing I'm setting up some avp variables.
>         When I'm
>         receiving a BYE request all avps are null. Why does this happen?
>         A part of the script:
>
>         if (has_totag())
>         {
>                if (loose_route())
>                {
>                        if (is_method("BYE"))
>                        {
>                                xlog("*** BYE $avp(i:2)");
>
>         From the docs
>         (http://www.opensips.org/Resources/DocsCoreVar#toc2):
>
>         "AVPs are part of the transaction context, so they will be visible
>         everywhere where the transaction is present. "
>
>         br,
>         takeshi
>
>
>         _______________________________________________
>         Users mailing list
>         Users at lists.opensips.org <mailto:Users at lists.opensips.org>
>         http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>
>      
>
>  
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> Users mailing list
> Users at lists.opensips.org
> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>   


-- 
Bogdan-Andrei Iancu
OpenSIPS Bootcamp
15 - 19 November 2010, Edison, New Jersey, USA
www.voice-system.ro




More information about the Users mailing list