might work

This commit is contained in:
Michael Jerger 2024-08-30 15:33:59 +02:00
parent c18a4c9a8b
commit e0e59e2620
3 changed files with 28 additions and 3 deletions

View file

@ -10,8 +10,10 @@
:deps :deps
{;; Application {;; Application
org.clojure/clojure {:mvn/version "1.11.4"} org.clojure/clojure {:mvn/version "1.11.4"}
org.clojure/spec.alpha {:mvn/version "0.5.238"} org.babashka/spec.alpha {:git/url "https://github.com/babashka/spec.alpha"
orchestra/orchestra {:mvn/version "2021.01.01-1"}} :git/sha "79e7daaead944583eece42ff5665be208d019861"}
orchestra/orchestra {:mvn/version "2021.01.01-1"}
babashka/babashka.curl {:mvn/version "0.1.2"}}
;; --------------------------------------------------------- ;; ---------------------------------------------------------
;; --------------------------------------------------------- ;; ---------------------------------------------------------

View file

@ -0,0 +1,11 @@
(ns dda.backup.monitoring
(:require
[dda.backup.monitoring.domain :as d]
[orchestra.core :refer [defn-spec]]))
(defn-spec send-monitoring any?
[config ::d/monitoring-config]
(curl/post
"http://pushgateway:9091/metrics/job/backup"
{:headers {"Content-Type" "application/json; schema=\"prometheus/telemetry\"; version=\"0.0.2\""}
:body (d/monitoring-data config)}))

View file

@ -10,4 +10,16 @@
;; --------------------------------------------------------- ;; ---------------------------------------------------------
#kaocha/v1 {} #kaocha/v1 {:plugins [:orchestra
:kaocha.plugin.alpha/info
:profiling
:print-invocations
:hooks
:notifier
:kaocha.plugin/version-filter]
:kaocha/bindings {kaocha.stacktrace/*stacktrace-filters* []
kaocha.stacktrace/*stacktrace-stop-list* []}
:reporter kaocha.report/documentation}