refactor: Reify protocol instead of interface

This commit is contained in:
Mathieu Lirzin 2026-01-01 17:40:47 +01:00
parent 2597d14125
commit e3180e4d6a
No known key found for this signature in database
GPG key ID: 0ADEE10094604D37

View file

@ -4,8 +4,7 @@
[io.pedestal.interceptor.chain :as chain] [io.pedestal.interceptor.chain :as chain]
[reitit.http] [reitit.http]
[reitit.interceptor]) [reitit.interceptor])
(:import (java.lang.reflect Method) (:import (java.lang.reflect Method)))
(reitit.interceptor Executor)))
;; TODO: variadic ;; TODO: variadic
(defn- arities [f] (defn- arities [f]
@ -46,7 +45,7 @@
(def pedestal-executor (def pedestal-executor
(reify (reify
Executor reitit.interceptor/Executor
(queue [_ interceptors] (queue [_ interceptors]
(->> interceptors (->> interceptors
(map (fn [{::interceptor/keys [handler] :as interceptor}] (map (fn [{::interceptor/keys [handler] :as interceptor}]