A small package to ingest a OpenAQ SQS queue.

Aurelien 039686bb22 Initial commit of openaq_ingestion. A small package to ingest a 6 年 前
openaq_ingestion 039686bb22 Initial commit of openaq_ingestion. A small package to ingest a 6 年 前
.gitignore 039686bb22 Initial commit of openaq_ingestion. A small package to ingest a 6 年 前
README.md 039686bb22 Initial commit of openaq_ingestion. A small package to ingest a 6 年 前
requirements.txt 039686bb22 Initial commit of openaq_ingestion. A small package to ingest a 6 年 前
settings.example.yaml 039686bb22 Initial commit of openaq_ingestion. A small package to ingest a 6 年 前
setup.py 039686bb22 Initial commit of openaq_ingestion. A small package to ingest a 6 年 前
test.py 039686bb22 Initial commit of openaq_ingestion. A small package to ingest a 6 年 前

README.md

Package to help import the openaq SQS queue in RDS.

Configuration

Copy settings.example.yaml to settings.yaml and set a valid database uri for storage. Set up AWS credentials in ~/.aws/ by using for example aws configure (if you have the AWS CLI installed). This package expects an SQS queue named openaq in the eu-west-1 region.

Usage

Two tooling entry points are defined:

  • initdb: initialize the database with the required table for openaq measurements.
  • processqueue: a utility to ingest the messages of the openaq queue:

    Usage: processqueue [OPTIONS]

    Options: --amount INTEGER Amount of messages to fetch. --delete BOOLEAN Delete messages from the queue after successful storage. --help Show this message and exit.