lib/gitlab_exporter/git.rb in gitlab-exporter-7.0.6 vs lib/gitlab_exporter/git.rb in gitlab-exporter-7.1.0

- old
+ new

@@ -60,11 +60,11 @@ # Handles creating a Git object, probing for both pull and push, and finally writing to metrics # # Optionally takes a metrics object which by default is a PrometheusMetrics, useful to change the # metrics writer to something else. class GitProber - def initialize(opts, metrics: PrometheusMetrics.new) + def initialize(opts, metrics: PrometheusMetrics.new, logger: nil) # rubocop:disable Lint/UnusedMethodArgument @metrics = metrics @labels = opts[:labels] || {} @git = Git.new(opts[:source]) end @@ -83,10 +83,10 @@ end end # A special prober for git processes class GitProcessProber - def initialize(opts, metrics: PrometheusMetrics.new) + def initialize(opts, metrics: PrometheusMetrics.new, logger: nil) # rubocop:disable Lint/UnusedMethodArgument @opts = opts @metrics = metrics end def probe_git # rubocop:disable Metrics/MethodLength