I do *think* that events are dispatched by different workers on the core indeed which might be the cause of your problem. ZMQ also has a few asserts on the core that can be quite disruptive and they were working on getting it working more properly. Dunno what's the status of that right now. A core dump would help a lot on any case tho. João Mesquita On Thu, Aug 16, 2012 at 4:23 PM, Alex Massover <alex@jajah.com> wrote:
Hello,
We're using mod_event_zmq module (slightly modified, we use different socket type and IPC instead of TCP), and experience crashes.
As far as I understood the module it creates ZMQ context and all event sent by using same context.
Events callback is called from different threads, isn't it? And can be a situation when different threads access send() api on this context simultaneously.
ZMQ guide strongly prohibits doing that: " You MUST NOT share ØMQ sockets between threads."
And when I do a mutex around send() there're no more crashes (at least today).
Am I missing something or mod_event_zmq is potentially dangerous?
-- Best Regards, Alex Massover _________________________________________________________________________ Professional FreeSWITCH Consulting Services: consulting@freeswitch.org http://www.freeswitchsolutions.com
FreeSWITCH-powered IP PBX: The CudaTel Communication Server http://www.cudatel.com
Official FreeSWITCH Sites http://www.freeswitch.org http://wiki.freeswitch.org http://www.cluecon.com
FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org