Skip to content

Commit 35fb27d

Browse files
author
Aleksei Lipniagov
committed
Remove worker label from puma terminations metric
1 parent c90effd commit 35fb27d

File tree

2 files changed

+2
-6
lines changed

2 files changed

+2
-6
lines changed

lib/gitlab/cluster/puma_worker_killer_observer.rb

+1-3
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,7 @@ def callback
1515
private
1616

1717
def log_termination(worker)
18-
labels = { worker: "worker_#{worker.index}" }
19-
20-
@counter.increment(labels)
18+
@counter.increment
2119
end
2220
end
2321
end

spec/lib/gitlab/cluster/puma_worker_killer_observer_spec.rb

+1-3
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,7 @@
1717
it 'increments timeout counter' do
1818
worker = double(index: 0)
1919

20-
expect(counter)
21-
.to receive(:increment)
22-
.with({ worker: 'worker_0' })
20+
expect(counter).to receive(:increment)
2321

2422
subject.callback.call(worker)
2523
end

0 commit comments

Comments
 (0)