zulip/humbug
Tim Abbott e55eb53297 Use get_user_profile_by_* functions to get UserProfiles.
We had a few bugs where we were using a raw Django database query to
get a UserProfile object.  This might seem OK, but going through
memcached is more efficient, and also guarantees that we get back the
.select_related() version of the object, so that if we later access
related fields like user_profile.realm.domain, we don't end up doing a
second database query as well.

Fixing these should in practice save a substantial number of database
queries on handling update_status_list requests, which happen very
often and access user_profile.realm.domain.

(imported from commit 0a2027da1b5bbc7a4f6c6927aca498530d7a4977)
2013-06-20 17:57:06 -04:00
..
__init__.py Initial Django commit: basic account, zephyr stream, narrowing, etc. 2012-08-28 12:44:51 -04:00
authhack.py Fix logging in with email addresses long than 30 characters. 2013-01-16 17:02:06 -05:00
backends.py Use get_user_profile_by_* functions to get UserProfiles. 2013-06-20 17:57:06 -04:00
settings.py Update a comment mentioning PipelineCachedStorage 2013-06-20 16:20:52 -04:00
test_settings.py Add a rate limiting system to our backend 2013-06-04 09:43:09 -04:00
urls.py Allows slashes at the end of links. 2013-06-06 15:14:28 -04:00
wsgi.py Remove more commented out example code 2012-10-29 23:21:00 -04:00