Export Scrapy spider stats to InfluxDB.
This package uses uv for project management. To get started, ensure that uv is installed on your machine and updated to the 0.5.6
version. Detailed installation instructions for uv can be found here.
uv add scrapy-influxdb-exporter
Add the following settings to your Scrapy project settings file:
INFLUXDB_DATABASE = ...
INFLUXDB_HOST = ...
INFLUXDB_MEASUREMENT_NAME = ...
INFLUXDB_ORG = ...
INFLUXDB_TOKEN = ...
STATS_CLASS = "scrapy_influxdb_exporter.InfluxDBStatsCollector"
uv sync --group=development
uv run pre-commit install --install-hooks
uv run pre-commit install --hook-type=commit-msg
This project was inspired by scrapy-prometheus-exporter by @rangertaha and this article by @mikulskibartosz.
Contributions are welcome! To get started, please refer to our contribution guidelines.
If you encounter any problems while using this package, please open a new issue here.