In a merge request with many discussions, the avatar URL can be called
thousands of times, inflicting a significant performance penalty
especially when avatars are stored in object storage. To mitigate this
problem, we can just cache the generated path any time it is requested.
Closes https://gitlab.com/gitlab-org/gitlab-ce/issues/55355
Every time a column in the projects table is changed, the Avatarable concern
would validate that the avatar file size was under 200K. This not only delays
the database changes, but it also can lead to unrelated failures if the HTTP
request fails for some reason.
Closes#51053