locked
system.Threading.Tasks.TaskCanceledException: A task was canceled RRS feed

  • Question

  • We are trying to run azure batch services.

    when we run the azure batch with 20 VMs',

     CloudPool pool = batchClient.PoolOperations.CreatePool(
                    poolId: poolId,
                    targetDedicated: vmstospin,             // 3 compute nodes
                    virtualMachineSize: "small",    // single-core, 1.75 GB memory, 225 GB disk
                    osFamily: "4");

    we are able to get the output to blob correctly. 

    When we assign more VMs like 100, we end up getting the error,

    system.Threading.Tasks.TaskCanceledException: A task was canceled. 

    We are not able to track down the root cause of the issue.

    Any help will be appreciated.

    Thursday, March 17, 2016 9:54 AM

Answers

  • Hi Selva,

    Can you share a bit more about this error -- is it consistently occurring when you call commit for the pool?

    Do you have a RetryPolicy configured for your batchClient?

    Can you also share the full stack trace of the exception you're encountering?

    From what I can tell given the information provided, I would think that this is a transient error which should not occur consistently, and that adding a retryPolicy would help -- but if you can provide the extra information above I can probably help more.

    Thursday, March 17, 2016 5:45 PM