I've been playing around with using freeswitch.EventConsumer in a lua process that starts-up when FS boots, and stays in the background. I've setup the example on the wiki, but the example uses session:execute("sleep",1000), and essentially loops every second until an event is fired. I'm wondering if there is a more event-driven way to accomplish this?<div>
<br></div><div>I tried asking for help in #lua, but they said the project (FS) needed to implement event-driven programming for this to work. To me, it seems sort of silly to implement freeswitch.EventConsumer without a way for it to be executed event-wise</div>
<div><br></div><div>Is using lua ESL the only option? There isn't any lua example scripts in libs/esl/lua to demonstrate how to handle events.</div><div><br></div><div>if mod_lua can't handle events, can the mod_javascript utilize it? Thanks.</div>
<div><br></div><div>--matt</div>