Scrapy 's Scrapyd too slow with scheduling spiders

有些话、适合烂在心里 提交于 2019-11-28 19:01:33

I've solved it by editing scrapyd/app.py on line 30.

Changed timer = TimerService(5, poller.poll) to timer = TimerService(0.1, poller.poll)

EDIT: The comment below by AliBZ regarding the configuration settings is a better way to change the polling frequency.

From my experience with scrapyd, it doesn't run a spider immediately as you schedule one. It usually waits a little bit, until the current spider is up and running, then it starts the next spider process (scrapy crawl).

So, scrapyd launches processes one by one until max_proc count is reached.

From your log i see that each of your spiders is running about 1 second. I think, you will see all your spiders running if they will run at least 30 seconds.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!