Hot code loading and modules Erlang (programming language)
for second version, add possibility reset count zero.
only when receiving message consisting of atom code_switch loop execute external call codeswitch/1 (?module preprocessor macro current module). if there new version of counter module in memory, codeswitch/1 function called. practice of having specific entry-point new version allows programmer transform state required in newer version. in our example keep state integer.
in practice, systems built using design principles open telecom platform leads more code upgradable designs. successful hot code loading tricky subject; code needs written care make use of erlang s facilities.
Comments
Post a Comment