This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2024-03-13
Channels
- # announcements (14)
- # babashka (13)
- # beginners (25)
- # biff (7)
- # calva (36)
- # clj-kondo (22)
- # clojure (31)
- # clojure-austin (1)
- # clojure-europe (12)
- # clojure-losangeles (4)
- # clojure-nl (1)
- # clojure-norway (61)
- # clojure-uk (4)
- # clojurescript (3)
- # datomic (24)
- # events (1)
- # humbleui (9)
- # leiningen (9)
- # lsp (30)
- # malli (3)
- # missionary (15)
- # off-topic (5)
- # re-frame (4)
- # reitit (7)
- # releases (2)
- # remote-jobs (4)
- # rewrite-clj (11)
- # ring-swagger (2)
- # sci (6)
- # xtdb (2)
- # yamlscript (3)
hello! i’m stuck with com.fasterxml.jackson.core/jackson-core 2.12.3
on Datomic Ions, where the latest metosin/jsonista
fails to compile. what’s the latest version of metosin/reitit
i can get away with? perhaps https://github.com/metosin/reitit/blob/0.5.18/project.clj?
We are using 0.6.0
(the latest non-alpha release) but with the caveat that you can't depend on the 'all bundled' reitit. Specifically, we found that it was reitit-swagger-ui
that caused the clash with datomic ions.
So instead of (which pulls in all modules):
[metosin/reitit "0.6.0"]
We list only the modules that we use:
metosin/reitit-core {:mvn/version "0.6.0"}
metosin/reitit-ring {:mvn/version "0.6.0"}
metosin/reitit-middleware {:mvn/version "0.6.0"}
metosin/reitit-malli {:mvn/version "0.6.0"}
metosin/reitit-swagger {:mvn/version "0.6.0"}
metosin/reitit-sieppari {:mvn/version "0.6.0"}
metosin/reitit-dev {:mvn/version "0.6.0"}
You might have to list some other modules, depending on if you use spec/schema/interceptors.
Remember that you have to remove the route that serves the swagger-ui. This is only the static assets for the front-end that is used to browse the API documentation, it does not affect the generation of swagger.json
file itself. We just host the swagger-ui somewhere else - it's just some HTML & JavaScript that you can get from the Swagger website (if you are using Swagger, that is).hi @U08AYNSSK, really great of you to help. thank you. we eventually settled on the same solution: use the latest stable reitit release excluding swagger-ui, and host the static ui somewhere else. it would have been nice to package the json and the ui in one place, but oh well 😎
Yip. Sorry I only saw this now, could've saved you some time investigating the issue again... 😆
In reitit, Is there a favorite way to set basic request info (url, method) that the Thread$UncaughtExceptionHandler
will see?
I could use thread-local storage, but it's often inadequate (e.g. what if I'm using an async server)
There's also dynamic bindings (as implied by e,g, timbre/with-context
) but those can be easily lost