by codesnik · 4y ago · 0 comments
And importing updated code to a live system sounds like a black magic. What happens while it's still in progress? Or does one have to start a new process, like we do in other frameworks? Erlang has live updates, but I imagine live update in smalltalk works very differently. So many questions!
> it's not only a code, it's a also current _state_ of the system
There is no difference in Smalltalk. The code includes all the created instances with current field values.
> updated code to a live system
From the user point of view everything is simple, yet the simplicity is the advantage of the compiler, not the user. If you update the code the instances that you upgrade run the new code, and if you don't upgrade the old objects they run the old code.
> I mean, for a web application most state should be in a database, but this takes some discipline.
This state could also reside in an image and Smalltalk has solutions like GemStone and Magma (OODBMS) solutions.
> And importing updated code to a live system sounds like a black magic.
Yeah, I don't think for most use cases this would be done. A new image would be built and deployed with the relevant code changes applied.