Join GitHub today
GitHub is home to over 20 million developers working together to host and review code, manage projects, and build software together.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
Already on GitHub? Sign in to your account
Add get endpoint for pushers #716
Conversation
dbkr
assigned
erikjohnston
Apr 11, 2016
dbkr
referenced this pull request
in matrix-org/sytest
Apr 11, 2016
Merged
Test for getting a user's pushers #227
erikjohnston
and 1 other
commented on an outdated diff
Apr 12, 2016
synapse/rest/client/v1/pusher.py
| @@ -27,14 +27,47 @@ | ||
| class PusherRestServlet(ClientV1RestServlet): | ||
| - PATTERNS = client_path_patterns("/pushers/set$") | ||
| + PATTERNS = client_path_patterns("/pushers(/set)?$") |
erikjohnston
Owner
|
erikjohnston
commented on an outdated diff
Apr 12, 2016
synapse/storage/pusher.py
| @@ -76,6 +76,25 @@ def r(txn): | ||
| defer.returnValue(rows) | ||
| @defer.inlineCallbacks | ||
| + def get_pushers_by_app_user_id(self, user_id): | ||
| + def r(txn): | ||
| + sql = ( | ||
| + "SELECT * FROM pushers" | ||
| + " WHERE user_name = ?" | ||
| + ) | ||
| + | ||
| + txn.execute(sql, (user_id,)) | ||
| + rows = self.cursor_to_dict(txn) | ||
| + | ||
| + return self._decode_pushers_rows(rows) |
erikjohnston
Owner
|
This was referenced Apr 12, 2016
dbkr
added some commits
Apr 12, 2016
|
ptal |
erikjohnston
commented on an outdated diff
Apr 12, 2016
erikjohnston
commented on an outdated diff
Apr 12, 2016
dbkr
added some commits
Apr 12, 2016
|
LGTM |
dbkr
merged commit d33d623
into
develop
Apr 12, 2016
8 checks passed
Flake8 + Packaging (Commit)
Build #394 origin/dbkr/get_pushers succeeded in 28 sec
Details
Flake8 + Packaging (Merged PR)
Build finished.
Details
Sytest Postgres (Commit)
Build #385 origin/dbkr/get_pushers succeeded in 5 min 49 sec
Details
Sytest Postgres (Merged PR)
Build finished.
Details
Sytest SQLite (Commit)
Build #390 origin/dbkr/get_pushers succeeded in 4 min 17 sec
Details
Sytest SQLite (Merged PR)
Build finished.
Details
Unit Tests (Commit)
Build #438 origin/dbkr/get_pushers succeeded in 1 min 9 sec
Details
Unit Tests (Merged PR)
Build finished.
Details
richvdh
deleted the
dbkr/get_pushers
branch
Dec 1, 2016
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
dbkr commentedApr 11, 2016
As per matrix-org/matrix-doc#308
Tested by matrix-org/sytest#227