XHTTP server: Add scStreamUpServerSecs
, enabled by default
#4306
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
#4113 (comment) 的相关测试发现 CF 会掐断下行 100 秒无实际数据的 HTTP,导致 stream-up 的上行方向被掐断,所以这个 PR 为服务端添加了
scStreamUpServerSecs
,默认值 "20-80" 取随机,服务端每隔这段时间就会发xPaddingBytes
个字节以保活这项机制只应针对新客户端(因为旧客户端会关闭连接),正好 #4298 是 breaking,基于 x_version 改为了基于 Referer header
可以设置
"scStreamUpServerSecs": -1
以关闭该机制,此时服务端甚至不会及时发 response header,和以前版本的行为相同所以这个 PR 终于为 #4253 的事业划上了句号,
并重新引入了 836e84b 的简单 recover,此外xPaddingBytes
不再能被关闭b786a50
NFT 半个月没动静了,你不捐我不捐,谁给你们开发 Xray,所以你懂的:0xDc3Fe44F0f25D13CACb1C4896CD0D321df3146Ee