Skip to content
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

无法返回自定义HTTP状态码 #819

Closed
linkyaa opened this issue Feb 4, 2024 · 4 comments
Closed

无法返回自定义HTTP状态码 #819

linkyaa opened this issue Feb 4, 2024 · 4 comments

Comments

@linkyaa
Copy link

linkyaa commented Feb 4, 2024

Ⅰ. Issue Description

websocket服务器在客户端升级时返回自定义的HTTP状态码1xxx,经过higress后变为502。

higress 用的是一键部署的默认配置

Ⅱ. Describe what happened

higress 日志

{
  "response_code":"502",
  "response_flags":"UPE"
}

Ⅲ. Describe what you expected to happen

Higress对自定义的状态码不做处理

Ⅵ. Environment:

  • Higress version: 1.3.2
@johnlanni
Copy link
Collaborator

这个是不符合RFC规范的,所以产生了UPE错误,Upstream Protocol Error

@johnlanni
Copy link
Collaborator

这个社区不能支持哈,太hack了

@linkyaa
Copy link
Author

linkyaa commented Feb 4, 2024

如果有和常规状态码语义进行区分需求,有什么好的建议吗

@johnlanni
Copy link
Collaborator

在websocket协议内部进行封装,修改协议升级的状态码是没办法穿透代理的

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants