<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=utf-8">
<meta name="Generator" content="Microsoft Word 14 (filtered medium)">
<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;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";}
h4
        {mso-style-priority:9;
        mso-style-link:"Heading 4 Char";
        mso-margin-top-alt:auto;
        margin-right:0in;
        mso-margin-bottom-alt:auto;
        margin-left:0in;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";
        font-weight:bold;}
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;}
p
        {mso-style-priority:99;
        mso-margin-top-alt:auto;
        margin-right:0in;
        mso-margin-bottom-alt:auto;
        margin-left:0in;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";}
pre
        {mso-style-priority:99;
        mso-style-link:"HTML Preformatted Char";
        margin:0in;
        margin-bottom:.0001pt;
        font-size:10.0pt;
        font-family:"Courier New";}
p.MsoAcetate, li.MsoAcetate, div.MsoAcetate
        {mso-style-priority:99;
        mso-style-link:"Balloon Text Char";
        margin:0in;
        margin-bottom:.0001pt;
        font-size:8.0pt;
        font-family:"Tahoma","sans-serif";}
span.EmailStyle18
        {mso-style-type:personal-reply;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
span.BalloonTextChar
        {mso-style-name:"Balloon Text Char";
        mso-style-priority:99;
        mso-style-link:"Balloon Text";
        font-family:"Tahoma","sans-serif";}
span.Heading4Char
        {mso-style-name:"Heading 4 Char";
        mso-style-priority:9;
        mso-style-link:"Heading 4";
        font-family:"Times New Roman","serif";
        font-weight:bold;}
span.HTMLPreformattedChar
        {mso-style-name:"HTML Preformatted Char";
        mso-style-priority:99;
        mso-style-link:"HTML Preformatted";
        font-family:"Courier New";}
.MsoChpDefault
        {mso-style-type:export-only;
        font-family:"Calibri","sans-serif";}
@page WordSection1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</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="EN-US" link="blue" vlink="purple">
<div class="WordSection1">
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;mso-line-height-alt:0pt;page-break-before:always">
<a name="section-21.1.5"></a><a href="http://tools.ietf.org/html/rfc3261#section-21.1.5"><b><span style="font-family:"Courier New";color:black">21.1.5</span></b></a><b><span style="font-family:"Courier New";color:black"> 183 Session Progress<o:p></o:p></span></b></p>
<p class="MsoNormal" style="page-break-before:always"><span style="font-family:"Courier New";color:black"><o:p> </o:p></span></p>
<p class="MsoNormal" style="page-break-before:always"><span style="font-family:"Courier New";color:black"><o:p> </o:p></span></p>
<p class="MsoNormal" style="page-break-before:always"><span style="font-family:"Courier New";color:black"> The 183 (Session Progress) response is used to convey information<o:p></o:p></span></p>
<p class="MsoNormal" style="page-break-before:always"><span style="font-family:"Courier New";color:black"> about the progress of the call that is not otherwise classified. The<o:p></o:p></span></p>
<p class="MsoNormal" style="page-break-before:always"><span style="font-family:"Courier New";color:black"> Reason-Phrase, header fields, or message body MAY be used to convey<o:p></o:p></span></p>
<p class="MsoNormal" style="page-break-before:always"><span style="font-family:"Courier New";color:black"> more details about the call progress.<o:p></o:p></span></p>
<p class="MsoNormal"><b><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></b></p>
<h4 style="mso-line-height-alt:0pt;page-break-before:always"><a name="section-21.1.2"></a><a href="http://tools.ietf.org/html/rfc3261#section-21.1.2"><span style="font-family:"Courier New";color:black">21.1.2</span></a><span style="font-family:"Courier New";color:black">
180 Ringing<o:p></o:p></span></h4>
<pre style="page-break-before:always"><span style="font-size:12.0pt;color:black"><o:p> </o:p></span></pre>
<pre style="page-break-before:always"><span style="font-size:12.0pt;color:black"><o:p> </o:p></span></pre>
<pre style="page-break-before:always"><span style="font-size:12.0pt;color:black"> The UA receiving the INVITE is trying to alert the user. This<o:p></o:p></span></pre>
<pre style="page-break-before:always"><span style="font-size:12.0pt;color:black"> response MAY be used to initiate local ringback.<o:p></o:p></span></pre>
<p class="MsoNormal"><b><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></b></p>
<p class="MsoNormal"><a href="http://tools.ietf.org/html/rfc3261#section-21.1.2">http://tools.ietf.org/html/rfc3261#section-21.1.2</a><b><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p></o:p></span></b></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<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""> asterisk-users-bounces@lists.digium.com [mailto:asterisk-users-bounces@lists.digium.com]
<b>On Behalf Of </b>Mordechay Kaganer<br>
<b>Sent:</b> Tuesday, August 13, 2013 10:55 AM<br>
<b>To:</b> Asterisk Users Mailing List - Non-Commercial Discussion<br>
<b>Subject:</b> Re: [asterisk-users] SIP trunk and congestion handling<o:p></o:p></span></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p>B.H.<o:p></o:p></p>
<p>Asterisk 1.8.22<o:p></o:p></p>
<p>Thanks<o:p></o:p></p>
<div>
<p class="MsoNormal">On Aug 12, 2013 8:05 PM, "Shishir Pokharel" <<a href="mailto:Shishir.Pokharel@on24.com">Shishir.Pokharel@on24.com</a>> wrote:<o:p></o:p></p>
<div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">Which version of asterisk are you using ?
</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"> </span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"> </span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><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"">
<a href="mailto:asterisk-users-bounces@lists.digium.com" target="_blank">asterisk-users-bounces@lists.digium.com</a> [mailto:<a href="mailto:asterisk-users-bounces@lists.digium.com" target="_blank">asterisk-users-bounces@lists.digium.com</a>]
<b>On Behalf Of </b>Mordechay Kaganer<br>
<b>Sent:</b> Sunday, August 11, 2013 8:59 AM<br>
<b>To:</b> Asterisk Users Mailing List - Non-Commercial Discussion<br>
<b>Subject:</b> [asterisk-users] SIP trunk and congestion handling</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"> <o:p></o:p></p>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">B.H.<o:p></o:p></p>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"> <o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">Hello, all. We have a dialer software that runs outgoing telephony campaigns. We have been using it successfully with PRI cards, now we're evaluating it's use also with a SIP trunk.
Most of the things run perfectly good without a need to change anything except for dial string, but there's some strange problem with asterisk interpreting SIP result codes. <o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"> <o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">Our software is written in Java using asterisk-java library. It is using Asterisk's reason code from OriginateResponseEvent to determine if it should redial the number. Our consideration
is that if Asterisk returns reason code 8 (Congestion) this means that the call has never actually reached the destination number, and it's OK to try to redial again.<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"> <o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">But with SIP trunk, many times i can see a really strange sequence of events:<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"> <o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">After INVITE i get the following responses (example from a real conversation)<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">[17:01:40] SIP/2.0 100 Trying<o:p></o:p></p>
</div>
<div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">[17:01:40] SIP/2.0 183 Session Progress<o:p></o:p></p>
</div>
</div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">[17:01:51] SIP/2.0 480 Temporarily not available<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"> <o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">As far as i understand, this means that the remote phone was ringing for 10 seconds and then the call failed due to a timeout. As far as i understand, i'm supposed to get reason
code 3, but actually the java application gets OriginateResponseEvent with failure reason code 8.<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"> <o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">This behavior is hard to reproduce. I was trying with my own phone number and then i get the expected reason code 3, but i constantly get this situation running our customer's campaigns.<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"> <o:p></o:p></p>
</div>
<div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"> <o:p></o:p></p>
</div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">--
<o:p></o:p></p>
<div>
<div>
<p class="MsoNormal" dir="RTL" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-align:right;direction:rtl;unicode-bidi:embed">
<span lang="HE" style="color:#666666">משיח </span><span dir="LTR" style="color:#666666">NOW</span><span dir="RTL"></span><span dir="RTL"></span><span lang="HE" style="color:#666666"><span dir="RTL"></span><span dir="RTL"></span>!</span><span dir="LTR"><o:p></o:p></span></p>
</div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span style="color:#666666">Moshiach is coming very soon, prepare yourself!</span><span lang="AR-SA" dir="RTL"><o:p></o:p></span></p>
<div>
<p class="MsoNormal" dir="RTL" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-align:right;direction:rtl;unicode-bidi:embed">
<span lang="HE" style="color:#666666">יחי אדוננו מורינו ורבינו מלך המשיח לעולם ועד!</span><span dir="LTR"><o:p></o:p></span></p>
</div>
</div>
</div>
</div>
</div>
</div>
<p class="MsoNormal"><br>
--<br>
_____________________________________________________________________<br>
-- Bandwidth and Colocation Provided by <a href="http://www.api-digital.com" target="_blank">
http://www.api-digital.com</a> --<br>
New to Asterisk? Join us for a live introductory webinar every Thurs:<br>
<a href="http://www.asterisk.org/hello" target="_blank">http://www.asterisk.org/hello</a><br>
<br>
asterisk-users mailing list<br>
To UNSUBSCRIBE or update options visit:<br>
<a href="http://lists.digium.com/mailman/listinfo/asterisk-users" target="_blank">http://lists.digium.com/mailman/listinfo/asterisk-users</a><span lang="AR-SA" dir="RTL"><o:p></o:p></span></p>
</div>
</div>
</body>
</html>