Hello @Rachit Gaur - Apologies for the late response. RpcException is quite a generic error and I believe there may be an underlying issue:
Microsoft.Azure.WebJobs.Script.Workers.Rpc.RpcException on Rety
I have created one azure function using Node and I have implemented retry in that. To achieve this I am not handling the exception in catch and throwing the exception. In that case retry is working but its giving RpcException (Microsoft.Azure.WebJobs.Script.Workers.Rpc.RpcException). May I know what wrong I am doing or how can I handle this exception in retry flow?
host.json
"retry": {
"strategy": "exponentialBackoff",
"maxRetryCount": 3,
"minimumInterval": "00:00:10",
"maximumInterval": "00:01:00"
}
handling error
catch (error) {
const { retryContext } = context.executionContext;
if(retryContext.retryCount >= retryContext.maxRetryCount){
return handleErrorResponse(context, error)
}
throw error;
}
if the retry count is less then maxRetryCount (3 in my case). its going for retry but giving exception as well.
1 answer
Sort by: Most helpful
-
Mike Urnun 9,756 Reputation points Microsoft Employee
2021-10-22T01:56:16.477+00:00