mirror of
https://github.com/scrapy/scrapy.git
synced 2025-02-25 12:03:58 +00:00
added comment downloader backout policy
This commit is contained in:
parent
2ae11e9220
commit
dad05957f3
@ -42,6 +42,7 @@ class SiteInfo(object):
|
||||
return self.max_concurrent_requests - len(self.transferring)
|
||||
|
||||
def needs_backout(self):
|
||||
# use self.active to include requests in the downloader middleware
|
||||
return len(self.active) > 2 * self.max_concurrent_requests
|
||||
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user