Hi Peter,<br><br>Wow, that simplified things a lot....and yes, it should solve my problem...<br><br>thanks for mentioning this here...<br><br clear="all">Regards,<br><br>Vineet Menon<br><br><br>
<br><br><div class="gmail_quote">On 1 May 2012 15:35, Peter Dunkley <span dir="ltr">&lt;<a href="mailto:peter.dunkley@crocodile-rcs.com" target="_blank">peter.dunkley@crocodile-rcs.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">

<u></u>


  
  

<div>
Hi,<br>
<br>
All that mqueue does is queue a string.<br>
<br>
When the request arrives I suspend it with t_suspend().  I then queue the index and label returned from the suspend operation with mqueue.<br>
<br>
When I pull an item off the mqueue I get the index and label of a previously suspended transaction.  I can use t_continue() to resume processing of that SIP request.<br>
<br>
So by having multiple queues, distributing across those queues according to priority, and then pulling stuff off the queues in the right order you can:<br>
1) Receive requests on Kamailio in the order they arrive<br>
2) But do any complex processing of them in an order based on whatever (arbitrary) priorities you choose<br>
<br>
Regards,<br>
<br>
Peter<div><div class="h5"><br>
<br>
On Tue, 2012-05-01 at 15:30 +0530, Vineet Menon wrote:<br>
<blockquote type="CITE">
    Peter,<br>
    You are telling about this module mqueue module, right....<br>
    if yes, then I understood the module incorrectly.<br>
    <br>
    I will get back after I understand it sufficiently....btw any other place to look for the info apart from the sources??<br>
    <br>
    <br>
    Regards,<br>
    <br>
    Vineet Menon<br>
    <br>
    <br>
    <br>
    <br>
</blockquote>
<blockquote type="CITE">
    On 1 May 2012 15:21, Peter Dunkley &lt;<a href="mailto:peter.dunkley@crocodile-rcs.com" target="_blank">peter.dunkley@crocodile-rcs.com</a>&gt; wrote:
</blockquote>
<blockquote type="CITE">
    <blockquote>
        As soon as messages are pulled from the receive buffer they are suspended and queued.  So it is the minimum processing required to pull them into Kamailio.  The let us say you have three queues.  Priority 1 messages are queued with queue 1, priority 2 in queue 2, priority 3 in queue 3.  Instead of dequeuing the queues in separate processes (as I do) you dequeue them in one process.  You empty queue 1 first, then queue 2, then queue 3.<br>


        <br>
        Won&#39;t that do what you want?
    </blockquote>
</blockquote>
<blockquote type="CITE">
    <blockquote>
        <br>
        <br>
        On Tue, 2012-05-01 at 14:55 +0530, Vineet Menon wrote:<br>
        <blockquote type="CITE">
            @peter,<br>
            I don&#39;t get it?? Your module mqueue seems to be doing IPC. What I want to do is prioratize messages that come to the server according to their behaviour...<br>
            What I want is to have n queue : <br>
            <br>
                                     _______________________________________________________<br>
                                    |                                       Prio 1                                                 |<br>
                                    |_______________________________________________________|<br>
                                    |                                       Prio 2                                                 |<br>
                                    |_______________________________________________________|               _______<br>
            ______             |                                       Prio 3                                                 |               |   OUT  \<br>
            |   IN    \            |_______________________________________________________|               |______ /<br>
            |______/                                                      / /<br>
                                                                             \ \<br>
                                                                             / /  <br>
                                    |                                       Prio n                                                 |<br>
                                    |_______________________________________________________|<br>
            <br>
            IN would come from the OS (messages which has been identified as SIP messages)<br>
            OUT would go to the kamailio processing part. i.e. it would now be actually reach the kamailio core.<br>
            <br>
            Regards,<br>
            <br>
            Vineet Menon<br>
            <br>
            <br>
            <br>
            <br>
            On 1 May 2012 14:23, Peter Dunkley &lt;<a href="mailto:peter.dunkley@crocodile-rcs.com" target="_blank">peter.dunkley@crocodile-rcs.com</a>&gt; wrote:<br>
            <blockquote>
                Hi,<br>
                <br>
                I have been using a configuration file based system to share certain SIP requests across different queues for handling by different processes.  Such a scheme could be adapted for prioritisation.<br>
                <br>
                I have posted several configuration fragments for this on the list so you should find them if you look in the archives.  My email from 28 March (at around 14:44) is probably the closest to what you are wanting.<br>


                <br>
                Regards,<br>
                <br>
                Peter <br>
                <br>
                <br>
                On Tue, 2012-05-01 at 13:59 +0530, Vineet Menon wrote:<br>
                <blockquote type="CITE">
                    Hi Olle,<br>
                    <br>
                    What I want to do is test a &quot;hypothesis&quot; for congestion control using prioritized scheduling of messages....<br>
                    But thx for that input regarding the newer message queue module....i&#39;ll look into it...<br>
                    <br>
                    <br>
                    Regards,<br>
                    <br>
                    Vineet Menon<br>
                    <br>
                    <br>
                    <br>
                    <br>
                    On 1 May 2012 13:18, Olle E. Johansson &lt;<a href="mailto:oej@edvina.net" target="_blank">oej@edvina.net</a>&gt; wrote:<br>
                    <blockquote>
                        <br>
                        1 maj 2012 kl. 09:39 skrev Vineet Menon: <br>
                        <br>
                        &gt; Hi,<br>
                        &gt;<br>
                        &gt; I am new to kamailio module devel...<br>
                        &gt; I want to test a new scheduling for SIP messages... Can i do that with kamailio modules? or I should go for something else? probably kamailio core??<br>
                        <br>
                        <br>
                        Can you elaborate a bit more? What do you mean with scheduling for SIP messages?<br>
                        <br>
                        We have a few new modules where you can queue messages for later processing and time their transmission. Check those first.<br>
                        <br>
                        /O<br>
                        _______________________________________________<br>
                        sr-dev mailing list<br>
                        <a href="mailto:sr-dev@lists.sip-router.org" target="_blank">sr-dev@lists.sip-router.org</a><br>
                        <a href="http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-dev" target="_blank">http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-dev</a> <br>
                    </blockquote>
                    <br>
<pre>_______________________________________________
sr-dev mailing list
<a href="mailto:sr-dev@lists.sip-router.org" target="_blank">sr-dev@lists.sip-router.org</a>
<a href="http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-dev" target="_blank">http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-dev</a>
</pre>
                </blockquote>
                <br>
                <br>
                <table cellpadding="0" cellspacing="0" width="100%">
<tbody><tr>
<td>
<pre>-- 
Peter Dunkley
Technical Director
Crocodile RCS Ltd
</pre>
</td>
</tr>
</tbody></table>
                <br>
                _______________________________________________<br>
                sr-dev mailing list<br>
                <a href="mailto:sr-dev@lists.sip-router.org" target="_blank">sr-dev@lists.sip-router.org</a><br>
                <a href="http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-dev" target="_blank">http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-dev</a><br>
                <br>
            </blockquote>
            <br>
<pre>_______________________________________________
sr-dev mailing list
<a href="mailto:sr-dev@lists.sip-router.org" target="_blank">sr-dev@lists.sip-router.org</a>
<a href="http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-dev" target="_blank">http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-dev</a>
</pre>
        </blockquote>
        <br>
        <table cellpadding="0" cellspacing="0" width="100%">
<tbody><tr>
<td>
<pre>-- 
Peter Dunkley
Technical Director
Crocodile RCS Ltd
</pre>
</td>
</tr>
</tbody></table>
    </blockquote>
</blockquote>
<blockquote type="CITE">
    <blockquote>
        <br>
        _______________________________________________<br>
        sr-dev mailing list<br>
        <a href="mailto:sr-dev@lists.sip-router.org" target="_blank">sr-dev@lists.sip-router.org</a><br>
        <a href="http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-dev" target="_blank">http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-dev</a><br>
        <br>
    </blockquote>
</blockquote>
<blockquote type="CITE">
    <br>
<pre>_______________________________________________
sr-dev mailing list
<a href="mailto:sr-dev@lists.sip-router.org" target="_blank">sr-dev@lists.sip-router.org</a>
<a href="http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-dev" target="_blank">http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-dev</a>
</pre>
</blockquote>
<br>
<table cellpadding="0" cellspacing="0" width="100%">
<tbody><tr>
<td>
<pre>-- 
Peter Dunkley
Technical Director
Crocodile RCS Ltd
</pre>
</td>
</tr>
</tbody></table>
</div></div></div>

<br>_______________________________________________<br>
sr-dev mailing list<br>
<a href="mailto:sr-dev@lists.sip-router.org">sr-dev@lists.sip-router.org</a><br>
<a href="http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-dev" target="_blank">http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-dev</a><br>
<br></blockquote></div><br>