Commit 40bc81a4 authored by Ahmad Sherif's avatar Ahmad Sherif
Browse files

Unify parameter passing to prober classes

parent 024b6f42
......@@ -48,7 +48,7 @@ module GitLab
def run
validate! labels, source: source)
......@@ -20,7 +20,7 @@ module GitLab
# Probes the DB specified by opts[:connection_string] for dead tubles stats, then converts them to metrics
class DeadTuplesProber
def initialize(opts, metrics =
def initialize(opts, metrics:
@metrics = metrics
@collector = opts[:connection_string])
......@@ -62,10 +62,10 @@ module GitLab
# Optionally takes a metrics object which by default is a PrometheusMetrics, useful to change the
# metrics writer to something else.
class GitProber
def initialize(options, metrics:
def initialize(opts, metrics:
@metrics = metrics
@labels = options.labels || {}
@git =
@labels = opts[:labels] || {}
@git =[:source])
def probe_pull
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment