I think I understood..

I put
    if(!dmq_is_from_node()) dmq_t_replicate() 
after
handle_publish(), handle_subscribe() and t_release()

and now it work ok.
                


2017-11-28 16:11 GMT+03:00 Aidar Kamalov <aidar.kamalov@gmail.com>:
Hello,

I set up kamailio cluster. dmq_usrloc works fine, but PUSBLISH and SUBSCRIBE replication not.
If I make a call to first node I've got many(hundreds) PUBLISH messages from first node to first node and some messages (8 for example) to other nodes.
And second xnotice in config not executes. And errors n log ERROR: <core> [core/sr_module.c:1726]: get_int_fparam(): Unsupported param type for int value: 32

How to replicate publish and subscribe, is it wrong way?


my confiig:
request_route {
    if(is_method("KDMQ")) {
        if ($Rp == 5050) { dmq_handle_message(); exit; }
        else { drop; }
    }
.....
.....
    if(is_method("PUBLISH|SUBSCRIBE")) {
        if(!dmq_is_from_node()) {
            xnotice("AAAAAAAA");
            dmq_t_replicate("1");
            xnotice("AAAAAAAABBBBBBBBBBB");
        }
     }
 


2017/11/28 12:56:06.415601 192.168.8.213:5060 -> 192.168.8.213:5060
PUBLISH sip:34200@siptest. SIP/2.0
Via: SIP/2.0/UDP 192.168.8.213;branch=z9hG4bKc7a5.cee84051000000000000000000000000.0
To: <sip:34200@siptest>
From: <sip:34200@siptest.>;tag=ae81df16b5a52fc1f62f9b45f337e660-db10
CSeq: 10 PUBLISH
Content-Length: 556
User-Agent: kamailio (5.0.4 (x86_64/linux))
Max-Forwards: 70
Event: dialog
Expires: 125
Content-Type: application/dialog-info+xml

<?xml version="1.0"?>
<dialog-info xmlns="urn:ietf:params:xml:ns:dialog-info" version="0" state="full" entity="sip:34200@siptest.">
  <dialog id="898932197-5060-86@BJC.BGI.D.DB" call-id="898932197-5060-86@BJC.BGI.D.DB" direction="initiator">
    <state>Trying</state>
    <remote>
      <identity>sip:53003@siptest.t</identity>
      <target uri="sip:53003@siptest.tg"/>
    </remote>
    <local>
      <identity>sip:34200@siptest</identity>
      <target uri="sip:34200@siptest"/>
    </local>
  </dialog>
</dialog-info>

--
Aydar A. Kamalov



--
Aydar A. Kamalov