yada

orestis 2018-03-19T13:55:46.000603Z

I just read through yada’s docs and it seems a very well-crafted high-level library for HTTP. Are there plans within JUXT to continue to add “sister” libraries like bidi to address other aspects of modern web-dev like e.g. websockets, auth, i18n? And what about operational concerns like deployment, logging, monitoring etc?

orestis 2018-03-19T13:56:08.000022Z

I see there is an “edge” project that aims to tackle some of these things so perhaps?

dominicm 2018-03-19T14:10:06.000273Z

yada supports sse, which we generally prefer to websockets. auth is handled in yada too. i18n is something we have explored enough for our work, but there's some options about.

dominicm 2018-03-19T14:10:31.000254Z

Operationally, we do have roll/mach which we use for deployments. Mostly we're generating terraform based on our aero configs though.

dominicm 2018-03-19T14:10:38.000544Z

Logging - tools.logging works good.

dominicm 2018-03-19T14:10:47.000633Z

Monitoring, we're figuring this out ourselves right now 😛

dominicm 2018-03-19T14:10:54.000319Z

we use CloudWatch for a lot of things though.

orestis 2018-03-19T15:32:03.000428Z

I’ve only skimmed the docs so apologies if this is mentioned there — is there a way to add a pervasive middleware across all handlers/routes?

orestis 2018-03-19T15:32:18.000534Z

Or perhaps a bit more interestingly, across some handlers?

orestis 2018-03-19T15:33:05.000300Z

BTW, thanks for all this!

dominicm 2018-03-19T15:52:46.000176Z

@orestis yada doesn't have middleware 😛. It does have interceptors, you can add it to some by using clojure.walk/postwalk on a routing data structure.

orestis 2018-03-19T15:57:42.000428Z

Cool, sounds like having the resources being data structures enables a lot of cool stuff 🙂

borkdude 2018-03-19T17:21:08.000761Z

@orestis yes, that’s very convenient

tanzoniteblack 2018-03-19T17:23:55.000098Z

speaking of yada, anyone have thoughts on https://github.com/juxt/yada/pull/223 ; it's pretty simplistic and just allows you to directly pass the return schema directly through to https://github.com/metosin/ring-swagger/ ; currently the only thing that's preventing it is that the schema doesn't allow the key :schema in responses

tanzoniteblack 2018-03-19T17:24:07.000026Z

(and yes, of course we're speaking of yada on #yada )

2018-03-19T17:31:43.000480Z

looks good to me (didn’t try running it) I guess the next step would be to actually use the schema to check/validate the reply and not use it just for documentation.