App Engine:是否可以禁用传输编码:对大型静态文件进行分块?
作为此问题的后续问题,是否可以对大型静态文件禁用“Transfer-Encoding:Chunked”方法,从而强制返回 Content-Length?
我的网站提供一些 Flash 文件。小的(500-700kb)报告内容长度良好,但大的(大约 3MB)则没有,而是使用分块模式。
虽然文件下载得很好,但 Flash 预加载器不起作用,因为它无法判断文件有多长,因此无法判断加载的百分比。
编写动态处理程序来服务静态文件是我唯一的选择吗?
谢谢。
As a follow-up to this question, is it possible to disable the "Transfer-Encoding: Chunked" method for large static files, therefore forcing a Content-Length to be returned instead?
My site serves a few Flash files. The small ones (500-700kb) report a Content-Length fine, but the large one (approx 3MB) doesn't, instead using chunked mode.
Although the file downloads fine, the Flash preloader doesn't work, because it can't tell how long the file is, and therefore what percentage is loaded.
Is my only option to write a dynamic handler to serve the static file?
Thanks.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
Transfer-Encoding 位于禁止的 HTTP 响应标头列表中(修改它们没有效果)。 来源
Transfer-Encoding is in the list of Disallowed HTTP Response Headers (modifying them has no effect). source