Safe dynamic software updates through software transactions
Dynamic software evolution is important not only for debugging, where a program can be tested and fixed interactively, without restarting it over and over again, but also for live software updates. The latter is especially interesting for web and other server-based applications, where downtimes are expensive and should be avoided as far as possible, but where regular software updates are still necessary to add and change functionality on the fly.
In object-oriented programming languages, software updates are typically performed with low-level language constructs that allow changing class or method definitions at runtime, or replacing objects with new, updated instances of potentially different classes. Such operations perform side effects on the data structures in the runtime system that represent class definitions and their hierarchies. Such side effects can become problematic in the presence of multithreading: Since the class graph is a global program resource, an update of a class definition in one thread may have uncontrolled effects in other threads [1].
Recently, software transactional memory (STM) has been introduced to bring the notion of transactions from databases to data structures in main memory. STM has been shown to ease implementing concurrent programs with side effects to shared memory, without involving locks or any other explicit synchronization mechanisms [2]. The goal of this thesis is to combine the idea of dynamic software updates with software transactional memory and to investigate whether this enables better handling of dynamic software evolution.
[1] Pascal Costanza, Dynamic Replacement of Active Objects in the Gilgul Programming Language, http://p-cos.net/documents/active-objects-gilgul-cd2002.pdf
[2] http://en.wikipedia.org/wiki/Software_transactional_memory