switchy icon indicating copy to clipboard operation
switchy copied to clipboard

Schedule commands should return proper futures

Open goodboy opened this issue 9 years ago • 0 comments

models.Session includes some methods which schedule future tasks with Freeswitch.

The details of how such tasks are cancelled or otherwise handled should be wrapped in an appropriate concurrent.futures.Future or asyncio.Future much like how Client.bgapi() returns instances our hand rolled future-like Job type. Maybe a Task is an even better analogue?

Further, we should adjust our current Job to be compatible with the new interface as it was originally based off multiprocessing.AsyncResult.

goodboy avatar Jan 04 '17 19:01 goodboy