commit | e3316fda268f5d1b6a049249ac67f45f88df1f3b | [log] [tgz] |
---|---|---|
author | Igor Bondarenko <jetmind2@gmail.com> | Fri Sep 19 12:26:33 2014 +0300 |
committer | Dave Brondsema <dbrondsema@slashdotmedia.com> | Mon Sep 22 18:14:15 2014 +0000 |
tree | d7c9d06fc23ae4cd1d996476241be0e5e5ee7738 | |
parent | 8c803cd02edb38601e20c74085f8515453f438d0 [diff] |
[#7644] ticket:658 Pre-populate roles cache to reduce # of mongo queries Also fix users_with_named_role so that it would actually use cache. Template for `/nf/new_projects/` displays admins for each project (and there can be a lot of projects) and it generates a lot of mongo queries to lookup user roles. Pre-populating the cache once helps to reduce query count more than twice, and improves overall page rendering time.