englercj / node-esl

FreeSWITCH ESL implementation for Node.js; implements the full Event Socket Library specified in: http://wiki.freeswitch.org/wiki/Esl
http://englercj.github.com/node-esl/
MIT License
170 stars 111 forks source link

method Connection.executeAsync -- callback() not called again #48

Closed Fleischers closed 8 years ago

Fleischers commented 9 years ago

Seems that callback not called when this.execAsync = true; Callback called only when I use sync version, just conn.execute

conn.setAsyncExecute(true); 
//Does not matter I use setAsyncExecute or executeAsync, it not called
conn.execute(task.app, task.arg, function (evt) { // tried including uuid or with no uuid supplied
    console.log('connection:execute callback:'); //never gets called with async
});

I was on version v1.1.2 and first thought it could be a problem and then updated to v1.1.5, but it not helped. What can be else wrong?

UPDATE: I used Node v0.10

It look similar to issue on previous versions https://github.com/englercj/node-esl/issues/46

Fleischers commented 8 years ago

@englercj Hello, can you check this issue?

englercj commented 8 years ago

Have you tried v1.1.6? This sounds simiar to #51, fsw isn't properly sending CHANNEL_EXECUTE_COMPLETE so you have to do manually uuid tracking to make it work. v1.1.6 added the ability to get the execute UUID so you can track events on it.

I don't have an fsw deployment or work with telephony anymore (or for quite some time) so I don't really have a way to look into this anymore than that. Hopefully this helps a bit.

Fleischers commented 8 years ago

@englercj Yes, I have tried with version 1.1.6 today, but it seems that FSW itself stucks when trying to launch executes in Async mode. So maybe it is just FSW side. I switched to use only "sync" mode of library, which gives me callbacks, so it is somewhat resolved. Thanks you for the answer. Sad that this library does not actively maintained, but I appreciate your efforts to keep it stable. I close the issue, because I don't know what the true cause of the issue and it seems there is no one around to take care of that.


upd: I almost forgot that it was months ago when I first got this issue, but I have no choice just to think of workarounds. Maybe if I do some investigation in future and find a solution, I could end up with PR for the repo.

englercj commented 8 years ago

Awesome, sorry I don't move this project forward anymore; I just don't work on anything that would use it anymore. :(