java怎么实现跳转到指定页面
295
2022-09-22
【Azure 应用服务】Azure Function HTTP Trigger 遇见奇妙的500 Internal Server Error: Failed to forward request to
问题描述
使用 Azure Funciton App,在本地运行完全成功的Python代码,发布到Azure Function就出现了500 Internal Server Error. 而且错误消息也是莫名的 Failed to forward request to Failed to forward request to a System.Net.Http.HttpRequestException exception after 562.442ms with message: Received an invalid status line: 'HTTP/1.1 1 '..Check application logs to verify the application is properly handling HTTP traffic.
问题解决
第29行代码为:
return func.HttpResponse(f"Logic Hello, {dresult}. This HTTP triggered function executed successfully.",status_code=1)
与默认生成的Python Function模板代码的区别只有 status_code 设置为了1. 默认的没有指定。
return func.HttpResponse(f"Hello, {name}. This HTTP triggered function executed successfully.")
如此可以成功判断: 是由于status_code为1导致了Failed to forward request to 得地址,因为无法在云环境中Debug而无从得出结论。
【如以后有更多的资料后,在进行分析。。。】
当在复杂的环境中面临问题,格物之道需:浊而静之徐清,安以动之徐生。 云中,恰是如此!
分类: 【Azure 应用服务】
标签: App Service, Azure Function, Failed to forward request to Internal Server Error
版权声明:本文内容由网络用户投稿,版权归原作者所有,本站不拥有其著作权,亦不承担相应法律责任。如果您发现本站中有涉嫌抄袭或描述失实的内容,请联系我们jiasou666@gmail.com 处理,核实后本网站将在24小时内删除侵权内容。
发表评论
暂时没有评论,来抢沙发吧~