Gitaly DeadlineExceeded with Repository#gitaly_merged_branch_names
Zendesk: https://gitlab.zendesk.com/agent/tickets/111754
Repository#gitaly_merged_branch_names
calls Gitlab::GitalyClient::RefService#merged_branches
with a fast timeout (10 seconds). In a large Linux repo with many branches, this will most likely timeout and cause a 500 when loading the /branches
endpoint.
Some ideas to fix this:
- Gracefully recover from the timeout and hide the merged branches view when the timeout occurs.
- Disable the merged branches view depending on some criteria (e.g. number of branch names etc.)
- Do this work asynchronously