I have had some fun in the last couple of weeks debating the Microsoft Rules Engine with Peter Lin. Many people in the BizTalk community will know that Peter used Amazon and The ServerSide site early this year to launch an attack on Microsoft’s representation of their rules engine.You can read the original thread here. Based on a BizTalkperformance whitepaper, the latest version of which is here, and on the documentation of the Rules Engine on MSDN, he deduced that that the engine does not implement the Rete algorithm correctly, does notsupport forward chaining inferencing and does not scale. For the uninitiated reader, the Rete (Latin for ‘Net’, pronounced “Ray-tee” according to my Latin-English dictionary, or “Ree-tee” if you believe everything you read on the Internet).algorithm is the most commonly used algorithm within inferencing rules engines, and implements a number of important optimisations by establishing, at runtime, a directed acyclic graph of memory nodes to representa rule set, andretaining information about matches as data (‘facts’) pass through the nodes.
At the time, Scott Woodgate had some involvement in the debate, and confirmed that the Microsoft Business Rules Engine does indeed implement the Rete algorithm (see his comments here). I regretted, at the time, not challenging Peter’s assertions, and over the months have had it in mind to tackle the issue at some point. My opportunity came a few weeks ago when the issue arose again on the TSS site. There has followed a debate in which I have chiefly aimed at showing that Peter has no grounds whatsoever for the claims he makes.You can read the threadhere. I cannot (and really don’t need to) ‘prove’ that Microsoft has implemented their engine correctly, but I can and doshow that the performance figures published by Microsoft provide no evidence of an incorrect implementation. To this end, I have published the results of some simpletestshere. Peter has also raised a number of concerns based on the documentation of the rules framework API, and has also highlighted the “side effects” feature. I do admit the the “side effects” feature is ‘impure’, although I consider it a very practical feature, but I contest that it somehow invalidates Microsoft’s implementation. Other API issues, such as Peter’s recent comments about the Assert class (see here), are based on a fundamental misunderstanding of what he is reading on MSDN.
If you enjoy this sort of stuff, do please feel free to read and join in the fun!!