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

Improve kernel API /api/network/forwardProxy #9110

Merged

Conversation

Zuoqiu-Yingyi
Copy link
Contributor

  • Please commit to the dev branch
  • For contributing new features, please supplement and improve the corresponding user guide documents
  • For bug fixes, please describe the problem and solution via code comments
  • For text improvements (such as typos and wording adjustments), please submit directly

gin 进行 json 序列化时会将非 UTF-8 字符替换为 \ufffd 导致 API /api/network/forwardProxy 无法获取正确的二进制响应体

本次改进如下所示

  • API 请求体添加参数 payloadEncodingresponseEncoding
    • 请求体 payload 使用 payloadEncoding 指定的编码方案
    • 响应体 body 使用 responseEncoding 指定的编码方案
  • API 响应体添加参数 bodyEncoding
    • 响应体 body 使用 bodyEncoding 指定的编码方案
    • bodyEncoding 与请求体中的 payloadEncoding 保持一致

已经过测试

@88250 88250 changed the title improve API /api/network/forwardProxy Improve kernel API /api/network/forwardProxy Sep 5, 2023
@88250 88250 added this to the 2.10.3 milestone Sep 5, 2023
@88250 88250 merged commit d99ac84 into siyuan-note:dev Sep 5, 2023
2 checks passed
@Zuoqiu-Yingyi Zuoqiu-Yingyi deleted the fix/api-network-forwardProxy-serializes branch September 5, 2023 05:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants