[prev in list] [next in list] [prev in thread] [next in thread] 

List:       openser-users
Subject:    [SR-Users] onsend_route showing wrong answer after forking
From:       Aymeric Moizard <amoizard () gmail ! com>
Date:       2018-09-26 10:28:16
Message-ID: CALM7LKNDvbwxqnb5TLeap7AcwQDiAZ9PWLNGOoPQqDJnYYv1eQ () mail ! gmail ! com
[Download RAW message or body]

[Attachment #2 (multipart/alternative)]


Hi,

I'm experimenting "onsend_route" with "onsend_route_reply=yes"
to improve my logs.

I was surprised to see that "onsend_route" doesn't always display
the "forwarded" answer after negative final answers. The documentation seems
to indicate that this route will execute only if "the received reply is sent
out". -as I'm forking, the final 6xx answer is not "forwarded"
immediatly... and
I guess this is the reason it doesn't show.

Here comes a real strange use-case:

With forking enabled, only the last answer will appear in the
"onsend_route",
however, in some case, this is NOT the answer being forwarded.

Example:
1/ receive 603 decline from branch1
2/ a CANCEL is sent on branch2
3/ a 487 Request Terminated is received on branch2

What happens:
1/ onsend_route is showing "487 Request Terminated"
2/ 603 Decline is forwarded (as expected)

The documenation say:
"If set to 1 (yes, on), onsend_route block is executed for received replies
that are sent out. Default is 0."

This doesn't look to be correct. (either the doc, or the code?)

Is there any possibility to install a log in the script that
would log ALL *exact* replies being sent:
1/ the real forwarded ones
2/ and also the ones sent by kamailio directly.

May be this is possible with some "event_route"?

Tks a lot!
Aymeric

-- 
Antisip - http://www.antisip.com

[Attachment #5 (text/html)]

<div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div \
dir="ltr"><div><br></div>Hi,<div><br></div><div>I&#39;m experimenting \
&quot;onsend_route&quot; with &quot;onsend_route_reply=yes&quot;</div><div>to improve \
my logs.</div><div><br></div><div>I was surprised to see that \
&quot;onsend_route&quot; doesn&#39;t always display</div><div>the \
&quot;forwarded&quot; answer after negative final answers. The documentation \
seems</div><div>to indicate that this route will execute only if &quot;the received \
reply is sent</div><div>out&quot;. -as I&#39;m forking, the final 6xx answer is not \
&quot;forwarded&quot; immediatly... and</div><div>I guess this is the reason it \
doesn&#39;t show.</div><div><br></div><div>Here comes a real strange \
use-case:</div><div><br></div><div>With forking enabled, only the last answer will \
appear in the &quot;onsend_route&quot;,</div><div>however, in some case, this is NOT \
the answer being forwarded.</div><div><br></div><div>Example:</div><div>1/ receive \
603 decline from branch1</div><div>2/ a CANCEL is sent on branch2</div><div>3/ a 487 \
Request Terminated is received on branch2</div><div><br></div><div>What \
happens:</div><div>1/ onsend_route is showing &quot;487 Request \
Terminated&quot;</div><div>2/ 603 Decline is forwarded (as \
expected)</div><div><div><br></div><div>The documenation say:</div><div><span \
style="color:rgb(51,51,51);font-family:Arial,sans-serif;font-size:14px">&quot;If set \
to 1 (yes, on), onsend_route block is executed for received replies that are sent \
out. Default is 0.</span>&quot;<br></div><div><br></div><div>This doesn&#39;t look to \
be correct. (either the doc, or the code?)</div><div><br></div><div>Is there any \
possibility to install a log in the script that</div><div>would log ALL *exact* \
replies being sent:  </div><div>1/ the real forwarded ones</div><div>2/ and also the \
ones sent by kamailio directly.</div><br>May be this is possible with some \
&quot;event_route&quot;?<br><br>Tks a lot!<br>Aymeric<div><br></div>-- <br><div \
dir="ltr" class="gmail_signature"><img src="http://sip.antisip.com/am48.png">Antisip \
- <a href="http://www.antisip.com" \
target="_blank">http://www.antisip.com</a><br></div></div></div></div></div></div></div>



[Attachment #6 (text/plain)]

_______________________________________________
Kamailio (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic