Cache merge requests count in group pages sidebar
Related to https://gitlab.com/gitlab-org/gitlab/-/issues/243753 Similar to the [implementation for issues](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/49739), we could save page load time for all pages at a group level, by caching the merge requests count in the sidebar. The query for this count is performed in [`GroupsHelper#group_merge_requests_count`](https://gitlab.com/gitlab-org/gitlab/-/blob/master/app/helpers/groups_helper.rb#L95) and called from [the sidebar partial](https://gitlab.com/gitlab-org/gitlab/-/blob/master/app/views/layouts/nav/sidebar/_group.html.haml#L2). At the date this issue was created, and for `GitLab.org` group, this query takes ~50ms. ![Screen_Shot_2021-01-22_at_12.49.19](/uploads/668b5cba32fdfb7ab0851cfe1a0cccd4/Screen_Shot_2021-01-22_at_12.49.19.png) To be determined: * Do we also want to cache and round this count only after a certain value?
issue