Run 'git gc' every 10 pushes
Merge request reports
Activity
Reassigned to @rspeicher
cc @dblessing
mentioned in issue #14250 (closed)
Reassigned to @DouweM
I am just curious? Why have you done this? Is this to reduce load on GitLab.com? And because it's going to be done every 10 pushes? @jacobvosmaer
@voarsh which 'this' are you asking about?
The reason for running GC frequently is to help performance. The 1-hour lease timeout is because I hope that most/all 'git gc' runs finish in under 1 hour.
Added 1 commit:
- 0beae70e - Use strings instead of symbols
27 "Housekeeping successfully started" 28 end 29 30 def needed? 31 @project.pushes_since_gc >= 10 32 end 33 34 def increment! 35 @project.pushes_since_gc += 1 36 @project.save! 37 end 38 39 private 40 41 def try_obtain_lease 42 lease = ::Gitlab::ExclusiveLease.new("project_housekeeping:#{@project.id}", timeout: LEASE_TIMEOUT) When you just got a new hammer everything looks like a nail.
@DouweM do you think there is some other solution I should have used?
Reassigned to @jacobvosmaer
Added 1 commit:
- 30b36c92 - Use an exception to pass messages
Reassigned to @DouweM
Enabled an automatic merge when the build for 30b36c92 succeeds
mentioned in commit ea7d062f
mentioned in issue #15021 (moved)