<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><meta http-equiv=Content-Type content="text/html; charset=us-ascii"><meta name=Generator content="Microsoft Word 12 (filtered medium)"><!--[if !mso]><style>v\:* {behavior:url(#default#VML);}
o\:* {behavior:url(#default#VML);}
w\:* {behavior:url(#default#VML);}
.shape {behavior:url(#default#VML);}
</style><![endif]--><style><!--
/* Font Definitions */
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
@font-face
        {font-family:Consolas;
        panose-1:2 11 6 9 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
pre
        {mso-style-priority:99;
        mso-style-link:"\0421\0442\0430\043D\0434\0430\0440\0442\043D\044B\0439 HTML \0417\043D\0430\043A";
        margin:0cm;
        margin-bottom:.0001pt;
        font-size:10.0pt;
        font-family:"Courier New";}
p.MsoAcetate, li.MsoAcetate, div.MsoAcetate
        {mso-style-priority:99;
        mso-style-link:"\0422\0435\043A\0441\0442 \0432\044B\043D\043E\0441\043A\0438 \0417\043D\0430\043A";
        margin:0cm;
        margin-bottom:.0001pt;
        font-size:8.0pt;
        font-family:"Tahoma","sans-serif";}
span.HTML
        {mso-style-name:"\0421\0442\0430\043D\0434\0430\0440\0442\043D\044B\0439 HTML \0417\043D\0430\043A";
        mso-style-priority:99;
        mso-style-link:"\0421\0442\0430\043D\0434\0430\0440\0442\043D\044B\0439 HTML";
        font-family:Consolas;}
span.EmailStyle19
        {mso-style-type:personal-reply;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
span.a
        {mso-style-name:"\0422\0435\043A\0441\0442 \0432\044B\043D\043E\0441\043A\0438 \0417\043D\0430\043A";
        mso-style-priority:99;
        mso-style-link:"\0422\0435\043A\0441\0442 \0432\044B\043D\043E\0441\043A\0438";
        font-family:"Tahoma","sans-serif";}
.MsoChpDefault
        {mso-style-type:export-only;}
@page WordSection1
        {size:612.0pt 792.0pt;
        margin:2.0cm 42.5pt 2.0cm 3.0cm;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="2050" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--></head><body lang=RU link=blue vlink=purple><div class=WordSection1><p class=MsoNormal><span lang=EN-US style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>Ok, thanks!<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'><o:p>&nbsp;</o:p></span></p><p class=MsoNormal><span style='font-size:10.0pt;font-family:"Arial","sans-serif";color:#1F497D'><o:p>&nbsp;</o:p></span></p><p class=MsoNormal><span style='font-size:10.0pt;font-family:"Arial","sans-serif";color:#1F497D'><o:p>&nbsp;</o:p></span></p><div><p class=MsoNormal><span style='color:#1F497D'><o:p>&nbsp;</o:p></span></p><table class=MsoNormalTable border=0 cellspacing=0 cellpadding=0 style='border-collapse:collapse'><tr><td width=431 colspan=2 valign=top style='width:323.3pt;padding:0cm 5.4pt 0cm 5.4pt'><p class=MsoNormal><span style='font-size:10.0pt;font-family:"Arial","sans-serif";color:#1F497D'><img width=377 height=3 id="_x0420__x0438__x0441__x0443__x043d__x043e__x043a__x0020_1" src="cid:image001.gif@01CB90B6.DA2FE290" alt=2><o:p></o:p></span></p></td></tr><tr><td width=143 valign=top style='width:107.55pt;padding:0cm 5.4pt 0cm 5.4pt'></td><td width=288 valign=top style='width:215.75pt;padding:0cm 5.4pt 0cm 5.4pt'></td></tr></table><p class=MsoNormal><span style='font-size:10.0pt;font-family:"Arial","sans-serif";color:#1F497D'><o:p>&nbsp;</o:p></span></p></div><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'><o:p>&nbsp;</o:p></span></p><div style='border:none;border-left:solid blue 1.5pt;padding:0cm 0cm 0cm 4.0pt'><div><div style='border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0cm 0cm 0cm'><p class=MsoNormal><b><span style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'>From:</span></b><span style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'> users-bounces@lists.opensips.org [mailto:users-bounces@lists.opensips.org] <b>On Behalf Of </b>mayamatakeshi<br><b>Sent:</b> Tuesday, November 30, 2010 5:29 PM<br><b>To:</b> OpenSIPS users mailling list<br><b>Subject:</b> Re: [OpenSIPS-Users] BYE processing and AVP<o:p></o:p></span></p></div></div><p class=MsoNormal><o:p>&nbsp;</o:p></p><p class=MsoNormal style='margin-bottom:12.0pt'><o:p>&nbsp;</o:p></p><div><p class=MsoNormal>On Tue, Nov 30, 2010 at 11:19 PM, mayamatakeshi &lt;<a href="mailto:mayamatakeshi@gmail.com">mayamatakeshi@gmail.com</a>&gt; wrote:<o:p></o:p></p><p class=MsoNormal><o:p>&nbsp;</o:p></p><div><p class=MsoNormal>2010/11/30 Anton Zagorskiy &lt;<a href="mailto:a.zagorskiy@oyster-telecom.ru" target="_blank">a.zagorskiy@oyster-telecom.ru</a>&gt;<o:p></o:p></p><div><blockquote style='border:none;border-left:solid #CCCCCC 1.0pt;padding:0cm 0cm 0cm 6.0pt;margin-left:4.8pt;margin-right:0cm'><p class=MsoNormal><o:p>&nbsp;</o:p></p><p class=MsoNormal>Why BYE isn't a part of the transaction?<o:p></o:p></p></blockquote></div><div><p class=MsoNormal><br>From RFC3261:<o:p></o:p></p><pre>Specifically, a SIP transaction consists of a single request and any responses to<br>&nbsp;&nbsp; that request, which include zero or more provisional responses and<br>&nbsp;&nbsp; one or more final responses.<o:p></o:p></pre><p class=MsoNormal>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).&nbsp; <o:p></o:p></p></div></div><div><p class=MsoNormal><br>For completeness,<br>the BYE is part of the dialog established by the INVITE transaction that ended when &quot;200 OK&quot; was received. But the BYE itself starts another transaction.<br>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.<br>&nbsp;<o:p></o:p></p></div><blockquote style='border:none;border-left:solid #CCCCCC 1.0pt;padding:0cm 0cm 0cm 6.0pt;margin-left:4.8pt;margin-right:0cm'><div><div><p class=MsoNormal><o:p>&nbsp;</o:p></p></div><div><div><blockquote style='border:none;border-left:solid #CCCCCC 1.0pt;padding:0cm 0cm 0cm 6.0pt;margin-left:4.8pt;margin-right:0cm'><p class=MsoNormal><br>WBR, Anton Zagorskiy<br>VoIP Developer, Oyster Telecom<br>Phone.: +7 812 601-0666<br>Fax: +7 812 601-0593<o:p></o:p></p><div><p class=MsoNormal><a href="mailto:a.zagorskiy@oyster-telecom.ru" target="_blank">a.zagorskiy@oyster-telecom.ru</a><o:p></o:p></p></div><p class=MsoNormal><a href="http://www.oyster-telecom.ru" target="_blank">www.oyster-telecom.ru</a><br><br><br>From: <a href="mailto:users-bounces@lists.opensips.org" target="_blank">users-bounces@lists.opensips.org</a><br>[mailto:<a href="mailto:users-bounces@lists.opensips.org" target="_blank">users-bounces@lists.opensips.org</a>] On Behalf Of mayamatakeshi<br>Sent: Tuesday, November 30, 2010 4:13 PM<br>To: OpenSIPS users mailling list<br>Subject: Re: [OpenSIPS-Users] BYE processing and AVP<o:p></o:p></p><div><div><p class=MsoNormal style='margin-bottom:12.0pt'><br><br>On Tue, Nov 30, 2010 at 10:07 PM, Anton Zagorskiy<br>&lt;<a href="mailto:a.zagorskiy@oyster-telecom.ru" target="_blank">a.zagorskiy@oyster-telecom.ru</a>&gt; wrote:<br>Hello.<br><br>During INVITE processing I'm setting up some avp variables. When I'm<br>receiving a BYE request all avps are null. Why does this happen?<br>A part of the script:<br><br>if (has_totag())<br>{<br>&nbsp; &nbsp; &nbsp; &nbsp;if (loose_route())<br>&nbsp; &nbsp; &nbsp; &nbsp;{<br>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;if (is_method(&quot;BYE&quot;))<br>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;{<br>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;xlog(&quot;*** BYE $avp(i:2)&quot;);<br><br>From the docs (<a href="http://www.opensips.org/Resources/DocsCoreVar#toc2" target="_blank">http://www.opensips.org/Resources/DocsCoreVar#toc2</a>):<br><br>&quot;AVPs are part of the transaction context, so they will be visible<br>everywhere where the transaction is present. &quot;<br><br>br,<br>takeshi<br><br><br><o:p></o:p></p></div></div><p class=MsoNormal>_______________________________________________<br>Users mailing list<br><a href="mailto:Users@lists.opensips.org" target="_blank">Users@lists.opensips.org</a><br><a href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users" target="_blank">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a><o:p></o:p></p></blockquote></div></div></div><p class=MsoNormal><o:p>&nbsp;</o:p></p></blockquote></div><p class=MsoNormal><o:p>&nbsp;</o:p></p></div></div></body></html>