From b9c99db1b205542f5b9f6aaabfe316a8d5b8d4a1 Mon Sep 17 00:00:00 2001 From: Clemens Date: Thu, 29 Aug 2024 10:45:52 +0200 Subject: [PATCH] rename burst-rate to max-concurrent-requests --- src/main/cljc/dda/c4k_keycloak/keycloak.cljc | 30 +++++++++++--------- 1 file changed, 16 insertions(+), 14 deletions(-) diff --git a/src/main/cljc/dda/c4k_keycloak/keycloak.cljc b/src/main/cljc/dda/c4k_keycloak/keycloak.cljc index b744a11..a98d05f 100644 --- a/src/main/cljc/dda/c4k_keycloak/keycloak.cljc +++ b/src/main/cljc/dda/c4k_keycloak/keycloak.cljc @@ -1,18 +1,20 @@ (ns dda.c4k-keycloak.keycloak - (:require - [clojure.spec.alpha :as s] - #?(:cljs [dda.c4k-common.macros :refer-macros [inline-resources]]) - #?(:clj [orchestra.core :refer [defn-spec]] - :cljs [orchestra.core :refer-macros [defn-spec]]) - [dda.c4k-common.yaml :as yaml] - [dda.c4k-common.common :as cm] - [dda.c4k-common.base64 :as b64] - [dda.c4k-common.ingress :as ing] - [dda.c4k-common.predicate :as cp])) + (:require + [clojure.spec.alpha :as s] + #?(:cljs [dda.c4k-common.macros :refer-macros [inline-resources]]) + #?(:clj [orchestra.core :refer [defn-spec]] + :cljs [orchestra.core :refer-macros [defn-spec]]) + [dda.c4k-common.yaml :as yaml] + [dda.c4k-common.common :as cm] + [dda.c4k-common.base64 :as b64] + [dda.c4k-common.ingress :as ing] + [dda.c4k-common.predicate :as cp])) (s/def ::fqdn cp/fqdn-string?) -(s/def ::namespace string?) (s/def ::issuer cp/letsencrypt-issuer?) +(s/def ::namespace string?) +(s/def ::max-rate int?) +(s/def ::max-concurrent-requests int?) (s/def ::keycloak-admin-user cp/bash-env-string?) (s/def ::keycloak-admin-password cp/bash-env-string?) @@ -20,9 +22,9 @@ :opt-un [::issuer ::namespace ::max-rate - ::burst-rate])) + ::max-concurrent-requests])) -(def auth? (s/keys :req-un [::keycloak-admin-user +(def auth? (s/keys :req-un [::keycloak-admin-user ::keycloak-admin-password])) #?(:cljs @@ -63,7 +65,7 @@ (cm/replace-all-matching "FQDN" fqdn) (cm/replace-all-matching "ADMIN_FQDN" (str "control." fqdn))))) ; TODO Document this -(defn-spec generate-service cp/map-or-seq? +(defn-spec generate-service cp/map-or-seq? [config config?] (let [{:keys [namespace]} config] (->