allow apitask to be cancellable