Make mirror MIN_DELAY configurable and MAX_RETRY adjust according to it
We should set Gitlab::Mirror::MIN_DELAY
configurable in the admin section since it is probably one of the most important settings for the mirroring, this will allow a user decide how many times he wants the mirror to run, eg: the default right now is 15 minutes.
After we apply this change we should also make Gitlab::Mirror::MAX_RETRY
adjust accordingly. The following formula should be the one used (sequence of triangular numbers) i += 1 while Gitlab::Mirror::MIN_DELAY * i * (i + 1) / 2 < 1440
and i
will give us the total amount of retries a mirror has to do to go through a full day.
After that the mirror will be marked as hard_failed and the user will be requested to take action.
\cc @DouweM