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

Implement basic ignore user API #763

Merged
merged 5 commits into from May 10, 2016

Conversation

Projects
None yet
2 participants
Owner

erikjohnston commented May 4, 2016

No description provided.

erikjohnston added some commits May 3, 2016

Contributor

NegativeMjark commented May 4, 2016

LGTM

@NegativeMjark NegativeMjark commented on an outdated diff May 4, 2016

synapse/storage/account_data.py
@@ -60,6 +63,28 @@ def get_account_data_for_user_txn(txn):
"get_account_data_for_user", get_account_data_for_user_txn
)
+ @cachedInlineCallbacks(num_args=2)
+ def get_global_account_data_by_type_for_user(self, user_id, data_type):
@NegativeMjark

NegativeMjark May 4, 2016 edited

Contributor

Given how this is used maybe this wants to be a cached list and for the function to take a list of userids rather than a single user?

Contributor

NegativeMjark commented May 5, 2016

Would it be an idea to create a special cached database API for getting the ignore list that could populate the cache with a default empty list if the user hasn't set an ignore list?

Owner

erikjohnston commented May 5, 2016

Would it be an idea to create a special cached database API for getting the ignore list that could populate the cache with a default empty list if the user hasn't set an ignore list?

In terms of performance or code neatness?

erikjohnston added some commits May 5, 2016

@erikjohnston erikjohnston merged commit e581754 into develop May 10, 2016

8 checks passed

Flake8 + Packaging (Commit) Build #628 origin/erikj/ignore_user succeeded in 29 sec
Details
Flake8 + Packaging (Merged PR) Build finished.
Details
Sytest Postgres (Commit) Build #612 origin/erikj/ignore_user succeeded in 4 min 29 sec
Details
Sytest Postgres (Merged PR) Build finished.
Details
Sytest SQLite (Commit) Build #619 origin/erikj/ignore_user succeeded in 3 min 20 sec
Details
Sytest SQLite (Merged PR) Build finished.
Details
Unit Tests (Commit) Build #672 origin/erikj/ignore_user succeeded in 1 min 22 sec
Details
Unit Tests (Merged PR) Build finished.
Details

@richvdh richvdh deleted the erikj/ignore_user branch Dec 1, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment