Skip to content

Retry and Task.Whenall() - does Retry "do the right thing"? #2879

Answered by cgillum
stevebus asked this question in Q&A
Discussion options

You must be logged in to vote

TL/DR: Task.WhenAll(...) will behave as you expect - it won't fail unless you exhaust the retry count.

Extended answer: The Task that gets returned by context.CallActivityWithRetryAsync(...) will not complete until either the activity function call succeeds or the retry policy expires. This means that the orchestration will not observe any intermittent failures because the tasks it create that have retry policies will just keep running. It also means that Task.WhenAll(...) won't fail unless the retry count is exhausted.

As far as the exception behavior of Task.WhenAll(...), it should behave the same as it did before - the await implementation of C# will expose just the first exception. If…

Replies: 2 comments 1 reply

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
1 reply
@stevebus
Comment options

Answer selected by stevebus
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants