This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2017-04-24
Channels
- # aws-lambda (1)
- # beginners (99)
- # boot (46)
- # cider (8)
- # cljs-dev (20)
- # cljsrn (37)
- # clojure (189)
- # clojure-dev (22)
- # clojure-dusseldorf (28)
- # clojure-italy (1)
- # clojure-russia (28)
- # clojure-spec (10)
- # clojure-uk (33)
- # clojurebridge (1)
- # clojurescript (64)
- # core-matrix (2)
- # css (3)
- # cursive (3)
- # datascript (34)
- # datomic (101)
- # defnpodcast (2)
- # dirac (5)
- # events (1)
- # funcool (3)
- # ldnclj (1)
- # lumo (11)
- # mount (1)
- # off-topic (95)
- # pedestal (2)
- # perun (10)
- # re-frame (3)
- # reagent (6)
- # ring-swagger (4)
- # specter (102)
- # test-check (1)
- # untangled (1)
- # vim (8)
- # yada (17)
having the following code:
(s/defschema A
{
:a s/Str
:b s/Int
})
(s/defschema B
{
:x s/Str
:y s/Int
})
(s/defschema R
(s/either A B))
(POST "/api" []
:return s/Any
:body [r R]
(ok r))
the parameters of the /api endpoint according to http://localhost:3000/swagger.json are:
"parameters": [
{
"in": "body",
"name": "R",
"description": "",
"required": true,
"schema": {
"$ref": "#/definitions/A"
}
}
], ...
why the schema
is “#/definitions/A” not “#/definitions/R” ???is there a smart way to log EVERY incoming request?
i'm looking at https://github.com/pjlegato/ring.middleware.logger but this line is confusing me:
(jetty/run-jetty (logger/wrap-with-logger my-ring-app) {:port 8080})