Again, I can't help on using app_java.

As for app_mono, which I developed more as an experiment, not really using it, sending a reply from a mono script is not possible at this moment. I exported just a few functions to the mono module, sending replies are not among them. If someone wants to take the lead and add new features to app_mono, I would happily assist.

The limitation of executing only config functions without parameter comes from the design of the config functions which do so called 'fixup' at startup -- this is a mechanism that pre-compile the parameters in a binary form, which is then used for executing the functions during runtime. Thus executing a function with string parameter can lead to a crash.

But you can return values back to the script via config variables and use them as parameter to sl send reply functions. See:

- http://www.kamailio.org/wiki/embeddedapi/4.1.x/mono#class_pv

In terms of embedded interpreters, app_lua has the largest set of Kamailio functions exported to Lua -- see its API in the wiki.

Cheers,
Daniel

On 11/09/14 22:03, Tom Johnson wrote:

Is there a way to call the send_reply method of the route from either Java or csharp?   As I have been having issues with the app_java, I have been looking at app_mono and it seems to have better access to the variables, etc.   However, the SR.core.ModF only seems to take methods that do not take parameters.

 

Or for that matter, is there a way to return something back to the route in the config file which it can use to call send_reply?  I have a strange requirement to return 202 rather than 200 from subscription requests and a 603 if it fails.

 

Tom Johnson |  Senior Software Engineer
O: 703-543-2118  |  F: 703-543-2099 
5870 Trinity Parkway, Suite 600, Centreville, VA  20120
cid:image001.png@01CE18AF.8F231EB0

 



_______________________________________________
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users

-- 
Daniel-Constantin Mierla
http://twitter.com/#!/miconda - http://www.linkedin.com/in/miconda
Next Kamailio Advanced Trainings 2014 - http://www.asipto.com
Sep 22-25, Berlin, Germany