ring

ikitommi 2018-07-25T07:58:57.000108Z

@dcreno for spec, you need the 2.0 alpha. It’s alpha mostly because spec is too…

👍 1
henrik 2018-07-25T14:09:01.000483Z

I’m encountering

java.lang.NoClassDefFoundError: javax/servlet/http/HttpServletRequest, compiling:(ring/middleware/multipart_params.clj:54:20)
` With any of the 4 latest versions of ring. Any ideas on how I can debug this one?

2018-07-25T15:20:07.000361Z

I’m looking for a hello-world type compojure-api 2.0 example to start from. Can’t find it anywhere, only this which isn’t super helpful at my level: https://github.com/metosin/compojure-api/wiki/Migration-Guide-to-2.0.0 Any suggestions?

ikitommi 2018-07-25T15:43:17.000107Z

@dcreno maybe https://github.com/jarcane/clojurice (it's 1.x, mut the syntax is the same) or https://github.com/yogthos/memory-hole (1.x too)

2018-07-25T15:45:45.000393Z

I should describe what I’m trying to do a little better… I understand and can use compojure-api but would like to start with spec instead of schema. I’m just intending to write an API service with integrated swagger docs.

ikitommi 2018-07-25T15:46:37.000491Z

@henrik see https://github.com/ring-clojure/ring/issues/251

henrik 2018-07-25T15:58:57.000018Z

@ikitommi I see, thank you. So the solution for the moment is for me to manually add the dep?

ikitommi 2018-07-25T16:01:28.000558Z

yes

👍 1
ikitommi 2018-07-25T16:02:36.000241Z

ok, there is a minimalistic sample at https://github.com/metosin/c2

2018-07-25T16:42:39.000124Z

that c2 example is great. Any guidance on which to choose, compjure-api vs reitit? I want spec, swagger, an API that I can do async functions in when necessary, but generally low performance requirements (1000 requests/day).

ikitommi 2018-07-25T17:37:08.000020Z

c-api is more proven, I might go with that. I think reitit is the future & with much better docs, but not all the batteries are there yet. Clojure Spec is still in alpha, and most likely will break the current contracts before finalizing. We try to keep the libs up with spec changes, but just remember it's alpha. Schema-support has been stable for years.

👍 1