I enjoyed this post too. It's one of the ones that's helping me
get a handle
on the concurrency options that are being considered for rubinius.
They're
currently leaning toward STM. MenTaLguY also shared a great list
of other
options at:
http://on-ruby.blogspot.com/2007/01/serial-rubinius-interview-
episode-v.html
I'm also extremely interested by STM. I've been reading the paper
about it, and I like it a lot.
Something I've been very interested in for about 12 years is some
research by the Empirical Modelling Group at Warwick University (UK).
They have this idea of dependency driven systems. Basically, imagine
that your programming language gives you spreadsheet like semantics
so that if a computation is dependent on some state, you can
automatically have that computation be re-run if any of its input
state changes. Unlike Model View Controller, you don't need to do any
subscription, it all just happens. The Warwick group implemented
these ideas in a number of experimental languages, notably Eden. I
now see nothing to stop the ideas being used in conventional
languages: they can be provided via an API.
Dependency based programming seems to remove a great deal of code and
cache state from programs - the language or API supports this for
you. It leads to simpler programs and makes them much more
composeable and mutable: you can easily stick bits of program
together without having designed them for such a purpose, and
programs parts can easily be re-used and modified.
The STM ideas seem to overlap enormously with Warwick dependency
work. A few extensions to the STM in the paper will let you know when
a transaction has become "stale" because some of the inputs it
observed have changed. Stale transactions should be re-run, and the
user shown their new output.
It's my belief that a bit of fundamental infrastructure we're missing
is an API that provides a distributed, STM. I think it also needs a
few extensions:
Versioning of data (Very useful anyway, but I think will also be
useful for allowing different parts of the global system to be
somewhat out of sych. which each other, which is probably essential
for many distributed applications),
De-centralisation (I think it's critical that anyone can see the
world as they wish, and share that view with anyone else. Critically,
this allows independent development, and for a kind of market place
of interfaces and data. It means you don't need centrally agreed
schema, things can evolve without needing to throw away your old data
and start again).
Lots of other things like signing / authentication / encryption /
relational queries would also be really good, but I'm not so
convinced that they're critical.
![Smile :) :)](data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7)
Sorry for rather a long post, but I hope it makes some sense.
Cheers,
Benjohn