scrapy 暂停恢复实现增量爬取

 

1、第一种方法:

  在scrapy  crawl 命令后面接上 -s JOBDIR/spidername 可以保存爬取状态实现 增量爬取。

scrapy crawl coolapk_info --logfile=app.log -s JOBDIR=    crawls/coolapk

 

2、

 

 

 

参考资料

1、 https://doc.scrapy.org/en/latest/topics/jobs.html

2、 http://stackoverflow.com/questions/7312093/how-can-i-stop-a-scrapy-crawlspider-and-later-resume-where-it-left-off 

3、 https://www.zhihu.com/question/19793879

posted @ 2017-05-11 20:04  xunux  阅读(743)  评论(0编辑  收藏  举报