People might find this interesting to compare and constrast to (certainly I noticed parallels with[1]) Netflix's 'serverless' platform, discussed yesterday: https://medium.com/netflix-techblog/developer-experience-les... Edit: As a sibling commenter notes this is most eminently doable with e.g. Common Lisp and BEAM (Erlang/Elixir), but more folks are (publicly) attempting this in other environments now (I've experime…
> Common Lisp and BEAM (Erlang/Elixir) Clojure as well right?
Hotswapping Haskell
11–20 of 36 posts
Re: Hotswapping Haskell
#12Earlier quoted context omitted.
I agree. Fun read and cool hack, but it definitely feels like they are stretching to justify the more fun of the two options (spend time on this or spend time fixing the root cause).
Glad you guys both can make a better trade off than the engineers that actually have their hands on the problem. /s You're reading a blog post, you do not know all they have tried, nor the various intricacies they're dealing with.
Re: Hotswapping Haskell
#13I don't want to knock the technical achievement here -- it's a cool hack -- but I'm really surprised that it was deemed to be the best choice for a production system. In the first place, "we can't compile our code on every change because it takes too long" is a really awful situation to be in. Are developers not building and testing their changes before deploying them? Can Facebook not afford a continuous integration…
The article describes the hot-swapped module as containing frequently changing business logic, which sounds like it’s something they can probably do via an interface with well-constrained or no mutability.
Re: Hotswapping Haskell
#14Earlier quoted context omitted.
I agree. Fun read and cool hack, but it definitely feels like they are stretching to justify the more fun of the two options (spend time on this or spend time fixing the root cause).
Glad you guys both can make a better trade off than the engineers that actually have their hands on the problem. /s You're reading a blog post, you do not know all they have tried, nor the various intricacies they're dealing with.
Re: Hotswapping Haskell
#15Re: Hotswapping Haskell
#16It's basically this: https://news.ycombinator.com/item?id=8804381 http://nullprogram.com/blog/2014/12/23/ You'd be surprised how many languages can do this. Though it's hard to beat lisp (and Erlang), where it is the default.
Loading / unloading code is straightforward. The trick is in getting the code called from existing code.
Re: Hotswapping Haskell
#17I don't want to knock the technical achievement here -- it's a cool hack -- but I'm really surprised that it was deemed to be the best choice for a production system. In the first place, "we can't compile our code on every change because it takes too long" is a really awful situation to be in. Are developers not building and testing their changes before deploying them? Can Facebook not afford a continuous integration…
I wonder why that wasn't an option for facebook.
[1] From podcast: http://www.haskellcast.com/episode/002-don-stewart-on-real-w...
Re: Hotswapping Haskell
#18Hotswapping just like security is one of those things that is hard to bolt on later, unless it is built in deeply into the very core of the language / runtime. Erlang (and Elixir) define hotswapping very well. It is a standard way to upgrade code in production in some places. And even with it being well defined it is still very hard and there are enough corner cases to handle. But when used correctly, it is really ma…
This is a huge feature for me in my Elixir development. I mostly use Elixir for some server code that manages many connections to external network entities. It would be a huge hassle to bring down my server application every time I want to make a change.
With Elixir (yeah, Erlang), I can normally recompile the module I'm working on and deploy it in the running server. Not only is it a good way to constantly observe Erlang hot-swapping in action on my dev machine, it's a huge time saver.
Re: Hotswapping Haskell
#19It's basically this: https://news.ycombinator.com/item?id=8804381 http://nullprogram.com/blog/2014/12/23/ You'd be surprised how many languages can do this. Though it's hard to beat lisp (and Erlang), where it is the default.
really, anyone who bothers reading the dlopen(3) manpage: http://man7.org/linux/man-pages/man3/dlopen.3.html Loading / unloading code is straightforward. The trick is in getting the code called from existing code.
Re: Hotswapping Haskell
#20We are going to be back in the 70ies/80ies of running live image programming-systems in no time. History repeats itself. Mark my words.