Label error responses with the component that caused the error to be generated
Everyone can contribute. Help move this issue forward while earning points, leveling up and collecting rewards.
Per slack discussion: https://gitlab.slack.com/archives/CB7P5CJS1/p1533231222000106
When Gitaly is unreachable to GitLab, a 503 page is generated by the latter. However, this 503 page is casually indistinguishable from the 503 page generated when GitLab is unreachable from Workhorse, or Workhorse from HAProxy.
As GitLab slowly becomes de-monolithized (and consider @ayufan's recent proposal to do more on this: https://gitlab.com/gitlab-org/gitlab-ce/issues/46499), debugging which component is failing will become more difficult.
I suggest that the component responsible for generating a 5xx error page (gitlab-rails in this case) include some indicator on the generated page about the component that is failing (e.g. gitaly, but it could be elasticsearch in EE when that's enabled, or any one of a range of other possible dependencies).
This implies that we also modify Workhorse so that it includes the same indicator if it can't talk to its dependencies, which would generally either be gitlab-rails or gitaly.
We could modify the text of the response page, or simply include it as a custom header, e.g., Failing-GitLab-Subsystem: gitaly
.
I really don't know how to go about mapping this to a product area, but I'm going to guess at ~Create /cc @jramsay