[asterisk-dev] Execution environment of Lua dialplan and persistent state?
dlakelan
dlakelan at street-artists.org
Thu Apr 7 14:54:37 CDT 2011
On 04/07/2011 11:27 AM, Matthew Nicholson wrote:
> On Wed, 2011-04-06 at 13:29 -0700, dlakelan wrote:
> [...some otherhelpful comments removed...]
> Yes, each channel gets it's own lua environment to run in.
>
Thanks. I wonder if it wouldn't be a good idea to have a supported way
to keep some lua state around. For example, perhaps a globalstate table?
Setting up and tearing down a mysql connection for each call route seems
not as nice as having a pool of mysql connections in a queue where we
could push and pop connections. I suppose this is being done from
different threads within Asterisk, so there would need to be locking
involved and that might be problematic. Anyway, this sort of thing would
be especially important for someone doing a really big dialplan where
they want to route it by results from a sql query or where dialing
certain extensions should provide information from the database via text
to speech or something like that.
More information about the asterisk-dev
mailing list