Hi, suppose one wants to be able to improve his sk...
# http4k
n
Hi, suppose one wants to be able to improve his skills to become able to write in http4k library style (coming for traditional oop).. are there any courses or books or talks or videos or tutorials or whatever you would recommend?
s
Our latest talk (source code) + examples repo should give a good idea of the style we have been promoting in the last few years. We don't have any public courses planned at the moment, but if your company would benefit from private training, please reach out to @dave and me here or via support@http4k.org
n
I see thanks Ivan
d
If you're talking about the http4k library style, then a lot of that is actually just fairly heavy use of FP-type practises (without the monadic stuff) - lots of composition of higher order functions/decoration and simple interfaces/typealiases along with a real synergy with the Kotlin language features. If that's what you're after then I'd recommend just studying the http4k source and the main concepts in the core - the main functions of httphandler/filter, the HttpMessage types, and the lens packages. You can see there quite a lot of the tricks we used to refine the APIs - like the hiding of concrete types behind factory functions in companion objects etc. We also have managed to get massive reuse of the main concepts throughout the various modules. If there's anything you see that you don't understand then feel free to ask here! 🙃 unfortunately there is no real shortcut to this style other than study - the entire library is the result of a combination of experience, the inspirational libraries (UtterlyIdle, Finagle, Fintrospect) and merciless refactoring until the design was refined. 🙃
n
"no shortcut other than study" .. i suspected that this would be the answer 😄 thanks Dave
d
We have been doing this tippy-tappy thing for a while now . #oldmen 🤣
s
ha - @Nicola, I didn't realise you were referring to the style of http4k itself (most people come here asking for tips to use the library). Sorry about that.
n
actually I need both types of improvement Ivan no need to be sorry, thanks again 😄
s
I'd add to Dave's answer that we tend to be strict about avoiding "magic" (reflection, annotation, etc) as much as we can.
n
Ok