-
Notifications
You must be signed in to change notification settings - Fork 2.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
request help: Distinguish the source (upstream or apisix) of the status code, whether it can be extended to all the status code #3963
Comments
There are many factors that cause 5xx status codes. We need to distinguish their sources and narrow the scope of the problem. The 4xx status codes are caused by client requests that do not conform to semantic specifications and have obvious prompt information. |
This is more intuitive to know the cause of the problem. Maybe we need to support distinguishing the source of 4xx status codes. |
In some special cases, other status codes may have similar problems. |
Actually, there are a bunch of headers can be added for the debugging purpose:
Of course, some information is sensitive, and maybe a switch should be introduced to show these data. |
@tokers That's a good suggestion. |
As the Thanks. |
This looks good, I think it is ok. |
We can send a proposal to the mail list, who wants to do this? |
Hi @fukiki , is that possible for you to send a proposal email to the dev mail list for further discussion? We actually need more opinions. Thanks. |
I think recording all non-2xx requests and provide a similar header of x-upstream-status is better. |
@liangliang4ward |
ok, let me try do this |
Issue description
There was a discussion earlier about
How to distinguish the source of these response status codes
:Issue 2501 and PR 2817.
The conclusion is that: In the response header of the request, through the response header of
X-APISIX-Upstream-Status
, we can effectively identify the source of the5xx
status code.About this, I have a question:
Why only distinguish 5xx status codes?
In some scenarios, the requirement may be how to distinguish the source of status codes 4xx.
In addition to this, We can rewrite the upstream status codes by APISIX's response-rewrite plugin. In this case, if we can't distinguish the source of the status code,upstream or apisix,it can’t quickly help us determine the problem.
Therefore, I would like to ask for some opinions of the community:
Distinguish the source (upstream or apisix) of the status code, whether it can be extended to all the status code,not only 5xx.
The text was updated successfully, but these errors were encountered: