简体   繁体   English

通过HTTP下载数据的最可靠方法

[英]The most reliable way to download data over HTTP

What is the most reliable choice of programming language / technology to perform requests and, most important, retrieve correct and full responses from an HTTP server which is under very heavy load, often yielding HTTP 503 Service Unavailable or just taking too much time to respond. 最可靠的编程语言/技术选择是执行请求,最重要的是从负载很重的HTTP服务器检索正确和完整的响应,这通常会导致HTTP 503服务不可用或花费太多时间来响应。 What is the way to retrive data from such server which will pretty much guarantee, that all data will be downloaded properly and in fastest possible time? 从这种服务器中检索数据的方法是什么,这可以保证在适当的最快时间内下载所有数据?

Given the situation where your application has no special treatment from the server, you will have to just keep trying until the server gives you the page. 考虑到您的应用程序没有服务器特殊处理的情况,您将不得不继续尝试直到服务器为您提供页面。

Keep in mind that this may be a very bad idea during actual server outages (not just high-load) so you may want to report failure to the user and tell them to try again later. 请记住,在实际服务器中断(不仅仅是高负载)期间,这可能是一个非常糟糕的主意,因此您可能希望向用户报告故障,并告诉他们稍后重试。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM