Hello all,<br><br>&nbsp;&nbsp;&nbsp;&nbsp; Got a question for those well versed on the Dialog Module. I have it working great against a db,&nbsp; but it seems to me that -although there&#39;s nothing on the module&#39;s documentations to indicate it- Dialogs are inserted on the table once the initial transaction is finished, i.e. 200 OK.<br>
<br>Here&#39;s my script...<br><br>#<br># $Id: openser.cfg 1827 2007-03-12 15:22:53Z bogdan_iancu $<br>#<br># simple quick-start config script<br># Please refer to the Core CookBook at <a href="http://www.openser.org/dokuwiki/doku.php">http://www.openser.org/dokuwiki/doku.php</a><br>
# for a explanation of possible statements, functions and parameters.<br>#<br><br># ----------- global configuration parameters ------------------------<br>debug=3&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; #&nbsp;&nbsp; debug level (cmd line: -dddddddddd)<br>fork=yes<br>
log_stderror=no&nbsp;&nbsp; # (cmd line: -E)<br>children=4<br>check_via=no<br>dns=no<br>rev_dns=no<br>listen=A.B.C.D<br>disable_dns_blacklist=true<br>port=5060<br><br>#set module path<br>mpath=&quot;/lib/openser/modules/&quot;<br><br>
# ------------------ module loading ----------------------------------<br>loadmodule &quot;mysql.so&quot;<br>loadmodule &quot;maxfwd.so&quot;<br>loadmodule &quot;sl.so&quot;<br>loadmodule &quot;dispatcher.so&quot;<br>loadmodule &quot;tm.so&quot;<br>
loadmodule &quot;mi_fifo.so&quot;<br>loadmodule &quot;textops.so&quot;<br>loadmodule &quot;xlog.so&quot;<br>loadmodule &quot;rr.so&quot;<br>loadmodule &quot;avpops.so&quot;<br>loadmodule &quot;dialog.so&quot;<br><br>modparam(&quot;mi_fifo&quot;,&quot;fifo_name&quot;, &quot;/tmp/openser_fifo&quot;)<br>
#Timer which hits if no final reply for a request<br>#or ACK for a negative INVITE reply arrives<br>modparam(&quot;tm&quot;, &quot;fr_timer&quot;, 5)<br><br>modparam(&quot;dispatcher&quot;, &quot;list_file&quot;, &quot;/etc/openser/dispatcher.list&quot;)<br>
modparam(&quot;dispatcher&quot;, &quot;flags&quot;, 2)<br>modparam(&quot;dispatcher&quot;, &quot;force_dst&quot;, 1)<br>modparam(&quot;dispatcher&quot;, &quot;dst_avp&quot;, &quot;$avp(i:271)&quot;)<br>modparam(&quot;dispatcher&quot;, &quot;grp_avp&quot;, &quot;$avp(i:272)&quot;)<br>
modparam(&quot;dispatcher&quot;, &quot;cnt_avp&quot;, &quot;$avp(i:273)&quot;)<br><br>modparam(&quot;avpops&quot;,&quot;avp_url&quot;,&quot;mysql://user:pass@localhost/openser&quot;)<br>modparam(&quot;avpops&quot;, &quot;avp_table&quot;, &quot;dialog&quot;)<br>
<br>modparam(&quot;rr&quot;,&quot;enable_full_lr&quot;, 1)<br><br>modparam(&quot;dialog&quot;, &quot;dlg_flag&quot;, 4)<br>modparam(&quot;dialog&quot;, &quot;db_mode&quot;, 1)<br>modparam(&quot;dialog&quot;, &quot;dlg_match_mode&quot;, 1)<br>
modparam(&quot;dialog&quot;, &quot;db_url&quot;, &quot;mysql://user:pass@localhost/openser&quot;)<br><br>route{<br>&nbsp;&nbsp;&nbsp; # initial sanity checks -- messages with<br>&nbsp;&nbsp;&nbsp; # max_forwards==0, or excessively long requests<br>&nbsp;&nbsp;&nbsp; if (!mf_process_maxfwd_header(&quot;10&quot;)) {<br>
&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; sl_send_reply(&quot;483&quot;,&quot;Too Many Hops&quot;);<br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; exit;<br>&nbsp;&nbsp;&nbsp; };<br><br>&nbsp;&nbsp;&nbsp; if (msg:len &gt;=&nbsp; 2048 ) {<br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; sl_send_reply(&quot;513&quot;, &quot;Message too big&quot;);<br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; exit;<br>
&nbsp;&nbsp;&nbsp; };<br><br>&nbsp;&nbsp;&nbsp;&nbsp; if(loose_route()) {<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; append_hf(&quot;P-hint: rr-enforced\r\n&quot;);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; route(1);<br>&nbsp;&nbsp;&nbsp;&nbsp; };<br>&nbsp;&nbsp;&nbsp;&nbsp; <br>&nbsp;&nbsp;&nbsp;&nbsp; if (!method==&quot;REGISTER&quot;)<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; record_route();<br><br>
&nbsp;&nbsp;&nbsp;&nbsp; if (method==&quot;INVITE&quot;) { <br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; setflag(4);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; xlog(&quot;L_ERR&quot;,&quot;OPENSER: NEW INVITE $ru -&gt; $ci \n&quot;);<br>&nbsp;&nbsp;&nbsp;&nbsp; };<br><br>&nbsp;&nbsp;&nbsp;&nbsp; if (method==&quot;BYE&quot;||method==&quot;CANCEL&quot;) {<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; setflag(4);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; xlog(&quot;L_ERR&quot;,&quot;OPENSER: DISCONNECT $ru -&gt; $ci \n&quot;);<br>&nbsp;&nbsp;&nbsp;&nbsp; };<br><br>&nbsp;&nbsp;&nbsp;&nbsp; if ( method==&quot;INVITE&quot; || method==&quot;ACK&quot; || method==&quot;BYE&quot; || method==&quot;OPTIONS&quot; || method==&quot;CANCEL&quot; ) {<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ds_select_dst(&quot;1&quot;,&quot;2&quot;);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; t_on_reply(&quot;1&quot;);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; t_on_failure(&quot;1&quot;);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; t_relay();<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; exit;<br>&nbsp;&nbsp;&nbsp;&nbsp; };<br>&nbsp;&nbsp;&nbsp;&nbsp; <br>}<br><br>route[1] {<br>
<br>&nbsp;&nbsp;&nbsp;&nbsp; #&nbsp;&nbsp;&nbsp; Forward Statefully<br>&nbsp;&nbsp;&nbsp;&nbsp; t_on_reply(&quot;1&quot;);<br>&nbsp;&nbsp;&nbsp;&nbsp; t_on_failure(&quot;1&quot;);<br>&nbsp;&nbsp;&nbsp;&nbsp; if(!t_relay()){<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; sl_reply_error();<br>&nbsp;&nbsp;&nbsp;&nbsp; };<br>&nbsp;&nbsp;&nbsp;&nbsp; exit;<br>}<br><br>failure_route[1] {<br><br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; if (t_check_status(&quot;408&quot;)) {<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; xlog(&quot;L_INFO&quot;,&quot;Marking GW as failed...\n&quot;);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ds_mark_dst(&quot;p&quot;);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ds_next_dst();<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; t_on_failure(&quot;1&quot;);<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; t_relay();<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; } else{<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; t_reply(&quot;501&quot;,&quot;Not Implemented&quot;);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; xlog(&quot;L_ERR&quot;,&quot;OPENSER: FAILED $ru -&gt; $ci \n&quot;);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }<br>
}<br><br><br><br><br>thanks to all<br><br><br>David<br>