Importance of a Context Map
A context is just a Clojure Map (https://clojure.org/reference/data_structures#Maps) that is taken as input by the interceptor and also generated as an output. It contains all the values that control a Pedestal application, including interceptors, chains, execution stacks, queues, and context values that may be generated by interceptors or required by interceptors remaining in the interceptor chain. A Context Map also contains a sequence of predicate functions. If any one of the predicate function returns true, the chain is terminated. All the required functions and signal keys are also defined within the Context Map to enable async capabilities and facilitate the interaction between the platform and interceptors. ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access