如果文件不返回源代码,则带宽问题

发布于 2024-10-17 08:19:40 字数 105 浏览 4 评论 0原文

我想知道如果您定期请求页面,需要多少(或者会浪费任何)带宽?

如果我使用 ajax 每 10 秒获取一个页面,并且该页面没有返回任何源代码,而且它实际上是空的,这会浪费任何带宽吗?

I was wondering how much (or would it waste any) bandwidth if you request a page at regular intervals?

If i used ajax to get a page every 10 seconds and the page returns no sourcecode whats so ever and its literaly empty, does this waste any bandwidth ?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

一片旧的回忆 2024-10-24 08:19:40

它仍然会在您的 Web 服务器上占用最短的时间,并且 HTTP 请求和响应标头仍然需要在客户端和服务器之间传输,所以是的,它仍然会占用 (最小)带宽量。

It'll still take up a "slot" on your web server for a minimal amount of time, and the HTTP request and response headers still need to be transferred between the client and the server, so yes it'll still take up a (minimal) amount of bandwidth.

爱已欠费 2024-10-24 08:19:40

我本来也是这么想的。几个字节(如果有),但您仍在调用文件。

I would have thought so. A few bytes if any, but you are still calling a file.

擦肩而过的背影 2024-10-24 08:19:40

您将获得包含请求和服务器确认的字节。

据推测,Web 服务器将返回 http 状态代码 200(正常)或 204(无响应),因此您将获得相应的标头数据。

You'll have the bytes comprising the request and the acknowledgement from the server.

Presumably the web server would be returning a http status code of 200 (OK) or 204 (No response) so you'll have the header data for that.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文