Push Message API
Python Other
Switch branches/tags
Clone or download
Latest commit 38c7b41 Apr 14, 2016
Permalink
Failed to load latest commit information.
bin run-prod.sh: add exec to gunicorn Apr 14, 2016
push_messages chore: tag 0.7 Apr 14, 2016
.clog.toml chore: add clog toml for changelog gen Mar 1, 2016
.dockerignore feat: add dockerized building per Dockerflow specs Apr 6, 2016
.gitignore test: add full test suite for unit tests and wsgi app Mar 1, 2016
.travis.yml test: add full test suite for unit tests and wsgi app Mar 1, 2016
CHANGELOG.md chore: tag 0.7 Apr 14, 2016
CONTRIBUTING.md chore: add initial project files and project base Mar 1, 2016
Dockerfile feat: add dockerized building per Dockerflow specs Apr 6, 2016
LICENSE chore: add initial project files and project base Mar 1, 2016
MANIFEST.in chore: add initial project files and project base Mar 1, 2016
Makefile feat: return 404 for no registered key, and refactor for redis only Apr 11, 2016
README.md docs: add architecture background Mar 3, 2016
app.py add beginning Feb 28, 2016
circle.yml feat: add circle.yml file for Dockerflow Apr 11, 2016
development.ini feat: return 404 for no registered key, and refactor for redis only Apr 11, 2016
production.ini feat: return 404 for no registered key, and refactor for redis only Apr 11, 2016
push_api.yaml fix: properly return no content for 204 Apr 12, 2016
requirements.txt feat: add dockerized building per Dockerflow specs Apr 6, 2016
setup.cfg chore: add initial project files and project base Mar 1, 2016
setup.py feat: add dockerized building per Dockerflow specs Apr 6, 2016
test-requirements.txt feat: return 404 for no registered key, and refactor for redis only Apr 11, 2016
tox.ini test: add full test suite for unit tests and wsgi app Mar 1, 2016

README.md

codecov.io Build Status

Push Messages API

A swagger driven Pyramid app that utilizes Redis for recent messages sent into the Mozilla Push System and manages crypto public keys that should have their recent message history recorded.

Architecture

This project provides an internal API for the Mozilla Push Developer Dashboard. Developers are identified by their registered VAPID public keys. A separate process populates those keys to a Redis database.

DynamoDB Table

Stores a permanent list of VAPID public keys that should have their message metadata extracted from the Mozilla Push Service logstream.

This is a very lightly used table managed by push_messages.

Redis

Stores a circular list of recent message metadata, indexed by VAPID public key. push_messages can retrieve this data via API calls. Redis supports efficient access/retrieval and has trim operations to emulate a circular list structure efficiently.

Developing

Checkout this repo, you will need Redis installed and a local DynamoDB to test against.

Then:

$ virtualenv pmenv
$ source pmenv/bin/activate
$ pip install -r requirements.txt
$ python setup.py develop

Edit the development.ini to point to your Redis database and set the DynamoDB table name to use.

Run the app locally:

$ pserve development.ini

It will then let you know where you can reach it.