My azure function works well locally and gives response 200 ok, however, although the remote deployment is successful, it throws response 500
I have been successful in testing my azure function locally. But whenver i try to test it remotely it fails with response 500 error. There is no problem with deployment as the deployment was termed successful.
I have looked into this issue, and tried to solve the problem. However, it seems that my local.settings.json and application settings are fine. Here is the snap shot of both.
My local.settings.json
My application settings from settings > configuration.
I also checked into to my Application Insights > Logs and ran the query for exceptions causing failures as below.
I found out that the exceptionType thrown was "Microsoft.Azure.WebJobs.Script.Workers.Rpc.RpcException" with failedMethod of "System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw". I investigated on this exception but was unable to find the root cause of my error.
I would highly appreciate if any prodigies in this field could help me out and resolve this issue. Thank you.