scrapy-redis adds a Redis queue scheduler, deduplication filter, and item pipeline so many Scrapy spiders and post-processors share work.
Overview
scrapy-redis provides Redis-based components for the Scrapy crawling framework. Multiple spider instances can pull requests from one shared Redis queue for broad multi-domain crawls.
Scraped items can be pushed to a Redis queue consumed by separate post-processing workers. Plug-in pieces include a scheduler with duplication filter, item pipeline, and base spider classes.
This fork extends queue payloads with JSON containing URLs, optional meta objects, and cookies for downstream FormRequest creation. Idle polling can use optional exponential backoff settings.
Requirements are Python 3.7+, Redis 5+, Scrapy 2+, and redis-py 4.2+. Installation is available from pip or source.
Key features
- Shared Redis request queue
- Distributed item pipeline
- Duplication filter
- JSON queue payloads
- Scrapy scheduler integration
- Idle poll backoff setting
Use cases
- Horizontal Scrapy crawling
- Distributed scrape pipelines
- Multi-spider URL feeds
- Redis-driven crawl farms