Documentation Index
Fetch the complete documentation index at: https://help.decodo.com/llms.txt
Use this file to discover all available pages before exploring further.
住宅代理
许多因素会影响住宅代理的速度:不同的ISP、位置、移动信号强度等。
尽管如此,我们的代理网络已针对最佳速度进行了优化,我们的平均代理响应时间可能从大约半秒到几秒不等,具体取决于国家和其他各种因素。
由于住宅代理的性质,某些IP比其他IP更快。如果您遇到速度问题,请尝试更改端口和/或端点。然后,运行几次测试以查看是否解决了问题。
您使用的工具也会影响代理速度。例如,网络浏览器连接总是会慢得多,因为它必须加载每个媒体文件。您自己的互联网连接和位置也会影响连接速度。
我们如何使用Python测试住宅IP速度
此Python代码向美国端点发送500个请求以进行轮换会话,并打印出单个请求所需的最低、最高和平均响应时间,以及500个请求中成功请求的数量。您只需要更改用户名和密码变量,当然,如果您愿意,也可以更改端点/端口。
import time
import requests
url = 'https://ip.decodo.com/ip'
username = 'user'
password = 'pass'
proxy = f'http://{username}:{password}@us.decodo.com:10000'
average = 0
lowest = 50
highest = 0
success = 0
for i in range(500):
start = time.time()
response = requests.get(url, proxies={'http': proxy, 'https': proxy})
end = time.time()
total = (end - start)
print(total)
average += total
if total < lowest: lowest = total
if total > highest: highest = total
if response.status_code == 200: success += 1
else: print(response.status_code)
if i == 499:
print("average: " + str(average / 500))
print("lowest: " + str(lowest))
print("highest: " + str(highest))
print("success: " + str(success))
数据中心代理
数据中心代理通常比住宅代理更快。为了获得最佳速度,您应该选择离您最近的代理。查看数据中心按流量付费代理提供的位置这里,以及数据中心按IP付费代理提供的位置这里。
反馈
找不到您要找的内容?请求一篇文章!
有反馈意见?分享您对我们如何改进的想法。