Used cached value of project count to reduce DB load

Merged Stan Hu requested to merge use-cached-project-count into master

Requires gitlab-org/gitlab-ce!5746

Possible fix for gitlab-com/infrastructure#303