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

Add health check for h2 & gRPC #747

Merged
merged 4 commits into from
Dec 21, 2021
Merged

Add health check for h2 & gRPC #747

merged 4 commits into from
Dec 21, 2021

Conversation

hecheng337
Copy link
Contributor

@hecheng337 hecheng337 commented Dec 20, 2021

草,后面的两个commit怎么也被自动合并进来了😂算了 那就一块吧

1,支持 Xray-core 的 H2/gRPC 健康检查功能,详见此处

2,新增选项,用于调整 initial_windows_size 。这个参数可以帮助解决gRPC在通过CloudFlare时出现的断流问题,具体的说明见文档。对应 Xray-core 的commit在 这里

3,新增选框 Bloom Filter,以支持 Xray-core v1.5.1 中的 Shadowsocks 安全增强功能,可能对防范重放攻击有所帮助。实际测试下,这个功能在服务端/客户端单边启用不会导致 '明显的' 兼容性问题,所以我将它默认设置为开;更多说明请见Xray的releases页面

4,这个算是我夹带的私货了 XD 。我昨天在尝试部署基于明文gRPC的代理服务(也就是h2c协议,走的是80端口)。同样的设置,其他设备都能正常使用,唯独SSR+插件用不了。阅读了 gen_config.lua 之后我才发现,gRPC 和 TLS 被绑定在了一起,后者被自动启用,导致了连接失败。我认为去除这一句判断对普通用户的影响不大,保留它反而是替用户做决定,影响到了某些正常的功能,所以就顺便去掉了 T^T

@1715173329
Copy link
Collaborator

Cc: @Mattraks

@hecheng337
Copy link
Contributor Author

呃啊,忽然发现这几个 timeout 的值其实还得加 o.datatype = "uinteger" 的限制 Orz
这是我头一次写lua,实在没能找到这一部分的文档,只好对照着上下文写 (X)
难免有些问题,还请海涵 (^_^)
我自己反复测试了一会,另外应该没什么问题了(大概)

Copy link
Collaborator

@1715173329 1715173329 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM - Thanks!

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

Successfully merging this pull request may close these issues.

3 participants