我总是遇到 500 Internal Server Error 是网络服务器错误,随后将其记录为错误。 但是,我被告知 500 Internal Server Error 也可能是应用程序错误。在这种情况下,发生这种情况时它似乎不会登录到网络服务器。
在某些情况下,500 内部服务器错误不会将问题报告到网络服务器错误日志中是否合理?
www.w3.org 报告:
Internal Error 500
The server encountered an unexpected condition which prevented it from fulfilling the request.
最佳答案
根据spec , HTTP 5xx 状态代码定义为服务器端 错误。任何导致 HTTP 5xx 错误的客户端问题都是对 HTTP 状态代码的不正确使用。阻止请求完成的客户端问题应导致 HTTP 4xx 状态代码。
6.6 Server Error 5xx
The 5xx (Server Error) class of status code indicates that the server is aware that it has erred or is incapable of performing the requested method. ...
-- https://www.rfc-editor.org/rfc/rfc7231#section-6.6
6.5 Client Error 4xx
The 4xx (Client Error) class of status code indicates that the client seems to have erred. ...
关于http - 500 Internal Server Error 是否总是意味着网络服务器错误?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/39149729/