after a few rethinks, a working implementation of pushers.

This commit is contained in:
David Baker 2014-12-18 14:49:22 +00:00
parent 88af58d41d
commit 9728c305a3
8 changed files with 158 additions and 73 deletions

View file

@ -18,7 +18,6 @@ CREATE TABLE IF NOT EXISTS pushers (
user_name TEXT NOT NULL,
kind varchar(8) NOT NULL,
app_id varchar(64) NOT NULL,
app_instance_id varchar(64) NOT NULL,
app_display_name varchar(64) NOT NULL,
device_display_name varchar(128) NOT NULL,
pushkey blob NOT NULL,
@ -27,5 +26,5 @@ CREATE TABLE IF NOT EXISTS pushers (
last_success BIGINT,
failing_since BIGINT,
FOREIGN KEY(user_name) REFERENCES users(name),
UNIQUE (user_name, pushkey)
UNIQUE (app_id, pushkey)
);