Hello all,
I'm using Kamailio with native script and KEMI in Javascript.
I noticed that functions from the TM module can have different results if I call them on KEMI or Native script. Is this intended behaviour? Don't they share the state?
In order to test this i made the following code :
KEMI Code : function ksr_request_route() {
try{ if ( KSR.is_method("BYE") ) {
print.error("BYE Request KEMI BYE")
KSR.route("exists_test")
if(KSR.tm.t_exists()) { print.error("KEMI : Transaction exists") } else { print.error("KEMI : Transaction does not exist") }
Native Code : route[exists_test] {
if( t_exists()) { xerr("Native Script : Transaction exists \n"); } else { xerr("Native Script : Transaction does not exist \n"); } }
I've also tried to change function call order but every time I get "Transaction does not exist" on native and "Transaction Exists" on KEMI.
Is this intended behaviour? Should I only call tm functions in native or Kemi in order to have consistency ?
Thanks in advance,
Best Regards,