updating task cancel api to remove old dispatch coordinator functionalit...

...y and adding ability to cancel spawned tasks