From bc2ef5d889c7743d6a9d78cc048e77bf675b6a52 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ivan=20Milo=C5=A1evi=C4=87?= Date: Wed, 6 May 2020 20:07:59 +0200 Subject: [PATCH] Fix ack qos2 counter MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Ivan Milošević --- src/mqtt_worker.erl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mqtt_worker.erl b/src/mqtt_worker.erl index ea40d02..377fa64 100644 --- a/src/mqtt_worker.erl +++ b/src/mqtt_worker.erl @@ -359,7 +359,7 @@ stats({pubrec_in, MsgId}, State) -> T2 = os:timestamp(), T1 = maps:get({outgoing, MsgId}, State), mzb_metrics:notify({"mqtt.publisher.qos2.pub_out_to_pubrec_in.latency", histogram}, positive(timer:now_diff(T2, T1))), - mzb_metrics:notify({"mqtt.publisher.qos2.pubrec.in.total"}, 1), + mzb_metrics:notify({"mqtt.publisher.qos2.pubrec.in.total", counter}, 1), mzb_metrics:notify({"mqtt.publisher.qos2.pubrec.waiting", counter}, -1), NewState = maps:update({outgoing, MsgId}, T2, State), NewState;