High performance Pub/Sub .NET libraries

In my search for a high-performance publish/subscribe library i again stumbled across the MS robotics CCR (Concurrency and Coordination Runtime).  The April CTP was just released an includes a number of new features including LINQ support.  The CCR remains stable and relatively unchanged, but new C# language features of lambdas and inline iterators open up new possibilities of writing streamlined async code and reduces problems with handling exceptions across threads due to the notion of Ports for success & failure scenarios.

Developers have typically steered clear of CCR given it is only bundled with MS Robotics studio (opting for alternatives such as the new TPL concurrency library), however the 200k CCR library can be shipped with your software at worst case costing US$2 per unit.

Some great examples include using CCR with ASP.NET to handle async requests showcasing iterators with yield keyword.  Another being a web crawler by Angle ‘Java’ Lopez which also leverages the DSS (decentralised software services).

An alternatives to this in-memory concurrent processing is publish/subscribe messaging over a reliable transport such as MSMQ some libraries include:

Async or concurrent programming is getting easier, and importantly more reliable.  Expect more posts and samples in the future.

Concurrent programming lesson with Erlang

I recently watched a very good presentation by Joe Armstrong – the inventor of Erlang, the functionality language originally developped for Ericsson telecom infrastructure products.  He is a very eloquent speaker, taking through the history of computing, explaining that moore’s law trajectory may in fact be restored if Network On Chip architectures take off in a big way.

I really like messaging framework approach to parallelism and immutable types are at the heart of this approach – a native construct in functional language such as F# on the .net platform.  Joe Duffy has written an article on archiving a degree of immutability in C#.

I dug a little deeper and came across a great open source library ‘Retlang‘ written by Mike Rettig (it’s name borrowing heavily from Erlang).  It currently uses native .NET 2 constructs, but I’m sure would benefit from running on top of Microsoft’s new parallel initiatives, especially as they mature in the future.