Utils for Pedestal
Utils for Pedestal
Plumatic Schema definition of a Pedestal Context
Plumatic Schema definition of a Pedestal Context
(context? map-in)
Inputs: [map-in :- tsk/KeyMap] Returns: s/Bool
Returns true if the map arg is a Pedestal context map
Inputs: [map-in :- tsk/KeyMap] Returns: s/Bool Returns true if the map arg is a Pedestal context map
Default options for configuring a Pedestal service
Default options for configuring a Pedestal service
(definterceptor name ctx)
Creates a Pedestal interceptor given a name and a map like (definterceptor my-intc { :enter <enter-fn> :leave <leave-fn> :error <error-fn> } )
Creates a Pedestal interceptor given a name and a map like (definterceptor my-intc { :enter <enter-fn> :leave <leave-fn> :error <error-fn> } )
(interceptor? map-in)
Inputs: [map-in :- tsk/KeyMap] Returns: s/Bool
Returns true if the map arg is a Pedestal interceptor map
Inputs: [map-in :- tsk/KeyMap] Returns: s/Bool Returns true if the map arg is a Pedestal interceptor map
(invoke-interceptors ctx interceptors)
Inputs: [ctx :- tsk/KeyMap interceptors :- [tsk/KeyMap]]
Given a context and a vector of interceptor-maps, invokes the interceptor chain and returns the resulting output context.
Inputs: [ctx :- tsk/KeyMap interceptors :- [tsk/KeyMap]] Given a context and a vector of interceptor-maps, invokes the interceptor chain and returns the resulting output context.
Plumatic Schema definition of a Pedestal Request
Plumatic Schema definition of a Pedestal Request
(request? map-in)
Inputs: [map-in :- tsk/KeyMap] Returns: s/Bool
Returns true if the map arg is a Pedestal request map
Inputs: [map-in :- tsk/KeyMap] Returns: s/Bool Returns true if the map arg is a Pedestal request map
(service-fn)
Returns the service-function
(which can be used for testing via pedestal.test/response-for)
Returns the `service-function` (which can be used for testing via pedestal.test/response-for)
(service-get & args)
Given that a Pedestal service has been defined, return the response for an HTTP GET request. Does not require a running Jetty server.
Given that a Pedestal service has been defined, return the response for an HTTP GET request. Does not require a running Jetty server.
(table-route route-map)
Inputs: [route-map :- TableRouteInfo] Returns: tsk/Tuple
Creates a Pedestal table-route entry from a context map.
Inputs: [route-map :- TableRouteInfo] Returns: tsk/Tuple Creates a Pedestal table-route entry from a context map.
Plumatic Schema definition of a Pedestal TableRouteInfo
Plumatic Schema definition of a Pedestal TableRouteInfo
(with-server service-map & forms)
Start & stop the server, even if exception occurs.
Start & stop the server, even if exception occurs.
(with-service service-map & forms)
Run the forms in the context of a Pedestal service definition
Run the forms in the context of a Pedestal service definition
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close