Skip to content

Project#empty_repo? is rather slow

Using the Method Calls dashboard I stumbled upon the following graph:

method_timings

This method does two things:

  1. Check if the repository exists
  2. Check if the repository has any branches

These two operations are simple enough that they should be doable in the order of milliseconds, not seconds. It could very well be that the slowdown is caused by the NFS and not the code itself.