Linda and Service Oriented Architectures

The September issue of Dr. Dobbs has an article (PDF) by Ron Bjornson and Andrew Sherman of TurboWorx on the use of Linda in Grid computing. Ron and Andrew both got their PhDs from Yale where Linda was developed by David Gelernter (As an aside, Gelernter is the Yale CS Prof who almost got blown up by the Unibomber.) If you're not familiar with Linda, its a programming model (i.e. it can be added to existing languages) that does interprocess communication using a free-form tuple space. Tuple spaces offer an alternative to message-oriented service oriented architectures like Web-services.

The primary difference between tuple-spaces and message-based system is that message-based systems require a delivery endpoint, or at least need a way to discover one. One process sends the message specifying the task to be done to another process. Tuple-spaces are more like bulletin board systems, where the originating process merely specifies a need and other processes meet that need as they can. Linda was the inspiration behind Jini's JavaSpaces.

This may sound like topic-based pub-sub systems, but there's a subtle difference. In tuple-spaces, processes search the tuple space, using a pattern language, for matches rather than subscribing to a particular topic. Consequently, you can use a tuple-space to implement a topic-based pub-sub system, but not the other way around. In the same way that searching on the Web is a small, but significance departure from Web-based directories, tuple-spaces are a small, but significant departure from message-based pub-sub systems.

Linda extensions are available for most languages. The chief disadvantage of using a tuple-space for creating your next service oriented architecture is that there's not real standard and no, as far as I know, public tuple spaces. This means that you have to have more control over the players in your SOA-based system than you would if you use Web services. Still, tuple-spaces have inherent advantages. Most conspicuous is that they ease the burden in creating fault tolerant systems. Tuple-spaces represent an extreme in loose coupling.