Channels ▼
RSS

MS Open Tech Cures Asynchronous Spaghetti Code Disease


Microsoft Open Technologies (MS Open Tech) is open sourcing Reactive Extensions (Rx), a programming model developed by Microsoft architect Erik Meijer that allows developers to glue together asynchronous data streams. As independent developer Dave Sexton puts it, "If asynchronous spaghetti code were a disease, Rx is the cure."

More Insights

White Papers

More >>

Reports

More >>

Webcasts

More >>

NOTE: Launched as a company subsidiary in April 2012 under the watchful eye of XML co-inventor and interoperability champion Jean Paoli, Microsoft Open Technologies is hoped to help major open source projects get better access to Windows code.

The Reactive Extensions (Rx) programming model is "particularly useful" in cloud programming because it creates a common interface for writing applications that stem from different, diverse asynchronous data sources. Data in this regard could come from (for example) stock quotes, Tweets, computer events (as in events, not get-togethers), and perhaps even web service requests.

The Rx source code will be hosted on the Microsoft open source code repository CodePlex to (hopefully) increase the community of developers seeking a more consistent interface to program against that works across several development languages. Its existence on CodePlex means that it is, logically and happily, also open to community contribution.

So why has Microsoft done this? Well, the goal of open sourcing Rx is essentially to expand the number of frameworks and applications that use Rx. This will achieve better interoperability across devices and the cloud.

According to Dave Sexton's blog, "It's a solid library built around core principles that hides much of the complexity of controlling and coordinating asynchrony within any kind of application. Opening it will help to lower the learning curve and increase the adoption rate of this amazing library, enabling developers to create complex asynchronous queries with relative ease and without any spaghetti code left over."

The following libraries are available on CodePlex:

Reactive Extensions

  • Rx.NET: The Reactive Extensions (Rx) is a library for composing asynchronous and event-based programs using observable sequences and LINQ-style query operators.
  • RxJS: The Reactive Extensions for JavaScript (RxJS) is a library for composing asynchronous and event-based programs using observable sequences and LINQ-style query operators in JavaScript, which can target both the browser and Node.js.
  • Rx++: The Reactive Extensions for Native (RxC) is a library for composing asynchronous and event-based programs using observable sequences and LINQ-style query operators in both C and C++.

Interactive Extensions

  • Ix: The Interactive Extensions (Ix) is a .NET library that extends LINQ to Objects to provide many of the operators available in Rx but targeted for IEnumerable<T>.
  • IxJS: An implementation of LINQ to Objects and the Interactive Extensions (Ix) in JavaScript.
  • Ix++: An implementation of LINQ for Native Developers in C++.

Bindings

  • Tx: A set of code samples showing how to use LINQ to events, such as real-time standing queries and queries on past history from trace and log files, which targets ETW, Windows Event Logs, and SQL Server Extended Events.
  • LINQ2Charts: An example for Rx bindings. Similar to existing APIs like LINQ to XML, it allows developers to use LINQ to create/change/update charts in an easy way. We would love to see more Rx bindings like this one.
  • With these libraries we are giving developers open access to both push-based and pull-based data via LINQ in Microsoft's three fundamental programming paradigms (native, JScript, and Managed code).


Related Reading






Currently we allow the following HTML tags in comments:

Single tags

These tags can be used alone and don't need an ending tag.

<br> Defines a single line break

<hr> Defines a horizontal line

Matching tags

These require an ending tag - e.g. <i>italic text</i>

<a> Defines an anchor

<b> Defines bold text

<big> Defines big text

<blockquote> Defines a long quotation

<caption> Defines a table caption

<cite> Defines a citation

<code> Defines computer code text

<em> Defines emphasized text

<fieldset> Defines a border around elements in a form

<h1> This is heading 1

<h2> This is heading 2

<h3> This is heading 3

<h4> This is heading 4

<h5> This is heading 5

<h6> This is heading 6

<i> Defines italic text

<p> Defines a paragraph

<pre> Defines preformatted text

<q> Defines a short quotation

<samp> Defines sample computer code text

<small> Defines small text

<span> Defines a section in a document

<s> Defines strikethrough text

<strike> Defines strikethrough text

<strong> Defines strong text

<sub> Defines subscripted text

<sup> Defines superscripted text

<u> Defines underlined text

Dr. Dobb's encourages readers to engage in spirited, healthy debate, including taking us to task. However, Dr. Dobb's moderates all comments posted to our site, and reserves the right to modify or remove any content that it determines to be derogatory, offensive, inflammatory, vulgar, irrelevant/off-topic, racist or obvious marketing or spam. Dr. Dobb's further reserves the right to disable the profile of any commenter participating in said activities.

 
Disqus Tips To upload an avatar photo, first complete your Disqus profile. | View the list of supported HTML tags you can use to style comments. | Please read our commenting policy.
 


Video