From 8231890ee4edc19a8e8923d5617fa202acdfc72e Mon Sep 17 00:00:00 2001 From: Andrey Antukh Date: Mon, 5 Feb 2024 20:10:44 +0100 Subject: [PATCH 1/3] :fire: Remove unnecesary line on audit ns --- backend/src/app/loggers/audit.clj | 1 - 1 file changed, 1 deletion(-) diff --git a/backend/src/app/loggers/audit.clj b/backend/src/app/loggers/audit.clj index e7a0184ac..45c36334a 100644 --- a/backend/src/app/loggers/audit.clj +++ b/backend/src/app/loggers/audit.clj @@ -347,7 +347,6 @@ (mark-as-archived [conn rows] (db/exec-one! conn ["update audit_log set archived_at=now() where id = ANY(?)" (->> (map :id rows) - (into-array java.util.UUID) (db/create-array conn "uuid"))]))] (db/with-atomic [conn pool] From 275c8b5860d8b82dd94d1045d0a233710b8c8a81 Mon Sep 17 00:00:00 2001 From: Andrey Antukh Date: Mon, 5 Feb 2024 20:10:57 +0100 Subject: [PATCH 2/3] :lipstick: Fix logging level on rpc climit ns --- backend/src/app/rpc/climit.clj | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/backend/src/app/rpc/climit.clj b/backend/src/app/rpc/climit.clj index 8d43a2cb5..2b83d5c22 100644 --- a/backend/src/app/rpc/climit.clj +++ b/backend/src/app/rpc/climit.clj @@ -45,7 +45,7 @@ [{:keys [::wrk/executor]}] (letfn [(on-remove [key _ cause] (let [[id skey] key] - (l/dbg :hint "disposed" :id (id->str id skey) :reason (str cause))))] + (l/trc :hint "disposed" :id (id->str id skey) :reason (str cause))))] (cache/create :executor executor :on-remove on-remove :keepalive "5m"))) @@ -86,7 +86,7 @@ (defn- create-limiter [config [id skey]] - (l/dbg :hint "created" :id (id->str id skey)) + (l/trc :hint "created" :id (id->str id skey)) (pbh/create :permits (or (:permits config) (:concurrency config)) :queue (or (:queue config) (:queue-size config)) :timeout (:timeout config) From 0e380a97cc22ac358c9229df2110640f45dd2782 Mon Sep 17 00:00:00 2001 From: Andrey Antukh Date: Mon, 5 Feb 2024 20:11:20 +0100 Subject: [PATCH 3/3] :lipstick: Add minor cosmetic improvement to worker ns --- backend/src/app/worker.clj | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/backend/src/app/worker.clj b/backend/src/app/worker.clj index 0e830ac9a..3a6bfe897 100644 --- a/backend/src/app/worker.clj +++ b/backend/src/app/worker.clj @@ -643,8 +643,12 @@ (def ^:private sql:remove-not-started-tasks - "delete from task - where name=? and queue=? and label=? and status = 'new' and scheduled_at > now()") + "DELETE FROM task + WHERE name=? + AND queue=? + AND label=? + AND status = 'new' + AND scheduled_at > now()") (s/def ::label string?) (s/def ::task (s/or :kw keyword? :str string?))