Adam,<br>This is great! so in the perl script you were just using the standard memcache libraries? Nice!<br><br><br><div class="gmail_quote">On Wed, Feb 18, 2009 at 1:01 PM, Adam Long <span dir="ltr"><<a href="mailto:ajlong@worldlink.net">ajlong@worldlink.net</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div link="blue" vlink="purple" lang="EN-US">
<div>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);">Hi Brett,</span></p>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);"> </span></p>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);">It was tested with very simple sip signaling. </span></p>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);">I benched with sipp with a very simple stateless script expecting
a MESSAGE req and essentially just replying with 200 OK if lookup was
successful and 404 if not.</span></p>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);"> </span></p>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);">I was actually approaching 20000cps with 2 sipp clients but
somewhere in between 10K and 20K I was getting retransmissions.</span></p>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);">Since those numbers were so much higher than I would ever need, I
didn't look into what was the cause and what was the exact point things
started "not working perfectly"</span></p>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);"> </span></p>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);">I filled a file with random routes one per line.</span></p>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);">And ran sipp as follows… </span></p>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);">sipp -i 10.200.1.21 -ci 10.200.1.21 10.200.1.10 -sf uac-msg.xml
-inf sip-users-cachetest.txt -r 20000 -m 1000000 -l 1000</span></p>
<p><span style="color: rgb(153, 153, 153);"> </span></p>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);">I attached the sipp scenario for you if you would like to do
your own tests.</span></p>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);">I don't have the exact script I used but it looked
something like this..</span></p>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);"> </span></p>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);">route {</span></p>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);"> if
(perl_exec("lookup_localdid")) {</span></p>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);"> sl_send_reply("200","OK");</span></p>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);"> }
else {</span></p>
<p style="text-indent: 0.5in;"><span style="font-size: 11pt; color: rgb(31, 73, 125);"> sl_send_reply("404","No
Route Found");</span></p>
<p style="margin-left: 0.5in;"><span style="font-size: 11pt; color: rgb(31, 73, 125);">} </span></p>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);"> exit;</span></p>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);">}</span></p>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);"> </span></p>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);">Regards,</span></p>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);">-Adam</span></p>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);"> </span></p>
<div style="border-style: solid none none; border-color: rgb(181, 196, 223) -moz-use-text-color -moz-use-text-color; border-width: 1pt medium medium; padding: 3pt 0in 0in;">
<p><b><span style="font-size: 10pt;">From:</span></b><span style="font-size: 10pt;"> Brett Nemeroff
[mailto:<a href="mailto:brett@nemeroff.com" target="_blank">brett@nemeroff.com</a>] <br>
<b>Sent:</b> Wednesday, February 18, 2009 1:14 PM<br>
<b>To:</b> Adam Long<div><div></div><div class="Wj3C7c"><br>
<b>Cc:</b> <a href="mailto:users@lists.opensips.org" target="_blank">users@lists.opensips.org</a><br>
<b>Subject:</b> Re: [OpenSIPS-Users] User inbound rules</div></div></span></p>
</div><div><div></div><div class="Wj3C7c">
<p> </p>
<p style="margin-bottom: 12pt;">Great! Thanks for the stats...<br>
Are those lookups independent of SIP signalling? I know memcache supports
well over 10K/sec.. Just curious if you'll get that performance with the perl
libs in the middle.<br>
-Brett<br>
<br>
</p>
<div>
<p>On Wed, Feb 18, 2009 at 12:11 PM, Adam Long <<a href="mailto:ajlong@worldlink.net" target="_blank">ajlong@worldlink.net</a>> wrote:</p>
<div>
<div>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);">I currently do this with 1.4.4
via perl and I use perl's libmemcached wrapper to vastly improve performance.</span></p>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);">I benched over 10000 lookups
per sec on a QC with mostly cached hits.</span></p>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);">With a full stateful routing
script I would expect only a 1/10<sup>th</sup> that but still very good.</span></p>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);"> </span></p>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);">I'm sure the 1.5 c based
memcache module functions would yield even better performance.</span></p>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);"> </span></p>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);">Regards,</span></p>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);">-Adam</span></p>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);"> </span></p>
<div style="border-style: solid none none; border-color: -moz-use-text-color; border-width: 1pt medium medium; padding: 3pt 0in 0in;">
<p><b><span style="font-size: 10pt;">From:</span></b><span style="font-size: 10pt;"> <a href="mailto:users-bounces@lists.opensips.org" target="_blank">users-bounces@lists.opensips.org</a>
[mailto:<a href="mailto:users-bounces@lists.opensips.org" target="_blank">users-bounces@lists.opensips.org</a>]
<b>On Behalf Of </b>Gustavo Mistrinelli<br>
<b>Sent:</b> Wednesday, February 18, 2009 10:01 AM<br>
<b>To:</b> Brett Nemeroff<br>
<b>Cc:</b> <a href="mailto:users@lists.opensips.org" target="_blank">users@lists.opensips.org</a><br>
<b>Subject:</b> Re: [OpenSIPS-Users] User inbound rules</span></p>
</div>
<div>
<div>
<p> </p>
<p style="margin-bottom: 12pt;">Thanks Brett, I'll take a look at the new
module :)</p>
<div>
<p>On Wed, Feb 18, 2009 at 12:47 PM, Brett Nemeroff <<a href="mailto:brett@nemeroff.com" target="_blank">brett@nemeroff.com</a>>
wrote:</p>
<p>Hi Gustavo,</p>
<div>
<p>I'm doing something similar, being that I need a lookup per INVITE. Bogdan's
recommendation for me was to use the memcaching functions in 1.5:</p>
</div>
<div>
<p><a href="http://www.opensips.org/index.php?n=Resources.DocsTutMemcache" target="_blank">http://www.opensips.org/index.php?n=Resources.DocsTutMemcache</a></p>
</div>
<div>
<p> </p>
</div>
<div>
<p style="margin-bottom: 12pt;"> </p>
<div>
<div>
<div>
<p>On Wed, Feb 18, 2009 at 8:45 AM, Gustavo Mistrinelli <<a href="mailto:gmistrinelli@gmail.com" target="_blank">gmistrinelli@gmail.com</a>>
wrote:</p>
</div>
</div>
<blockquote style="border-style: none none none solid; border-color: -moz-use-text-color -moz-use-text-color -moz-use-text-color rgb(204, 204, 204); border-width: medium medium medium 1pt; margin: 5pt 0in 5pt 4.8pt; padding: 0in 0in 0in 6pt;">
<div>
<div>
<p style="margin-bottom: 12pt;">Hi all, I'm trying to figure out if we can use
or add functionalities to dynamic routing module to do "incoming
routing" based on callee destination ($ru) per user<br>
The idea is to have inbound rules per user (username/domain or user aliases
i.e. numbers ) <br>
Each user will set their incoming rules, i.e. First rule ring my numbers and
username (lookup registered devices) for 15 seconds, then call my cellphone for
10 second, then call<br clear="all">
home number for 20 seconds and then call my voicemail, each step may ring on
more than one devices at the same time, it's a mix of serial and parallel
forking. Condition to do next step is if get 4XX errors (not found, busy, etc)<br>
We can add also time conditions and black/white list. <br>
<br>
I did it using custom avp_db_query but will be nice have rules on memory
without querying tables every time.<br>
<br>
I'll be waiting for your suggestions<br>
<br>
Best,<br>
<br>
-- <br>
<span style="color: rgb(136, 136, 136);">Gustavo Mistrinelli</span></p>
</div>
</div>
<p style="margin-bottom: 12pt;">_______________________________________________<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></p>
</blockquote>
</div>
<p> </p>
</div>
</div>
<p><br>
<br clear="all">
<br>
-- <br>
Gustavo Mistrinelli</p>
</div>
</div>
</div>
</div>
<p style="margin-bottom: 12pt;"><br>
_______________________________________________<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></p>
</div>
<p> </p>
</div></div></div>
</div>
<br>_______________________________________________<br>
Users mailing list<br>
<a href="mailto:Users@lists.opensips.org">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><br>
<br></blockquote></div><br>