<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:copyright="http://blogs.law.harvard.edu/tech/rss" xmlns:image="http://purl.org/rss/1.0/modules/image/">
    <channel>
        <title>- Business Rule Engine</title>
        <link>http://geekswithblogs.net/LeonidGaneline/category/5980.aspx</link>
        <description>- Business Rule Engine</description>
        <language>en-US</language>
        <copyright>Leonid Ganeline</copyright>
        <managingEditor>leo.gan.57@gmail.com</managingEditor>
        <generator>Subtext Version 0.0.0.0</generator>
        <item>
            <title>BizTalk 2006: Deploy the Policies with command line (BTSTask)</title>
            <link>http://geekswithblogs.net/LeonidGaneline/archive/2007/04/10/111316.aspx</link>
            <description>&lt;div&gt;It is not so strightforward as it suppose to be.&lt;/div&gt;
&lt;div&gt;Below are the bat files with comments:&lt;/div&gt;
&lt;div&gt; &lt;/div&gt;
&lt;div&gt;&lt;font face="Courier New"&gt;@rem ----------- Deploy.Policies.bat ---------------------------------------------&lt;br /&gt;
@call Settings.bat&lt;/font&gt;&lt;/div&gt;
&lt;div&gt;&lt;font face="Courier New"&gt;&lt;/font&gt; &lt;/div&gt;
&lt;div&gt;&lt;font face="Courier New"&gt;@ECHO. &lt;br /&gt;
@ECHO.  Deploy Policies: &lt;br /&gt;
@ECHO.  ======================================================================&lt;br /&gt;
@ECHO. &lt;/font&gt;&lt;/div&gt;
&lt;div&gt;&lt;font face="Courier New"&gt;&lt;/font&gt; &lt;/div&gt;
&lt;div&gt;&lt;font face="Courier New"&gt;@Time /T&lt;br /&gt;
@ECHO &lt;span style="background-color: rgb(255, 255, 153);"&gt;1) Create the ResourceSpec.xml file. &lt;/span&gt;&lt;br /&gt;
@rem BTSTask ListApp  /ApplicationName:%ApplicationName%  /Server:%BizTalkDataBasesServer% /Database:%BizTalkConfigurationDataBase% /ResourceSpec:"%CurrentBuildPath%\ResourceSpec.xml&lt;/font&gt;&lt;/div&gt;
&lt;div&gt;&lt;font face="Courier New"&gt;&lt;/font&gt; &lt;/div&gt;
&lt;div&gt;&lt;font face="Courier New"&gt;@Echo &lt;span style="background-color: rgb(255, 255, 153);"&gt;2) Then edit it to remain only Policy recources.&lt;/span&gt;&lt;/font&gt;&lt;/div&gt;
&lt;div&gt;&lt;font face="Courier New"&gt;&lt;/font&gt; &lt;/div&gt;
&lt;div&gt;&lt;font face="Courier New"&gt;@Echo &lt;span style="background-color: rgb(255, 255, 153);"&gt;3) Export .xml to .msi&lt;/span&gt;&lt;br /&gt;
@rem BTSTask ExportApp /ApplicationName:%ApplicationName% /Package:"%CurrentBuildPath%\Policies.msi" /ResourceSpec:"%CurrentBuildPath%\ResourceSpec.xml"  /Server:%BizTalkDataBasesServer% /Database:%BizTalkConfigurationDataBase%&lt;/font&gt;&lt;/div&gt;
&lt;div&gt;&lt;font face="Courier New"&gt;&lt;/font&gt; &lt;/div&gt;
&lt;div&gt;&lt;font face="Courier New"&gt;@Echo &lt;span style="background-color: rgb(255, 255, 153);"&gt;4) Import .msi (Before this Undeploy the existed policies, the /Overwrite doesn't help! Or Stop the Application.)&lt;/span&gt;&lt;br /&gt;
BTSTask ImportApp /Package:"%CurrentBuildPath%\Policies.msi" /ApplicationName:%ApplicationName% /Overwrite  /Server:%BizTalkDataBasesServer% /Database:%BizTalkConfigurationDataBase% &lt;/font&gt;&lt;/div&gt;
&lt;div&gt;&lt;font face="Courier New"&gt;&lt;/font&gt; &lt;/div&gt;
&lt;div&gt;&lt;font face="Courier New"&gt;@Echo &lt;span style="background-color: rgb(255, 255, 153);"&gt;5) Deploy policies one by one :((&lt;/span&gt;&lt;/font&gt;&lt;/div&gt;
&lt;div&gt;&lt;font face="Courier New"&gt;&lt;/font&gt; &lt;/div&gt;
&lt;div&gt;&lt;font face="Courier New"&gt;@set PolicyName=VesselID&lt;br /&gt;
@set PolicyVersion=1.27&lt;br /&gt;
BTSTask AddResource  /ApplicationName:%ApplicationName% /Type:System.BizTalk:Rules  /Overwrite /Name:%PolicyName% /Version:%PolicyVersion% /Server:%BizTalkDataBasesServer% /Database:%BizTalkConfigurationDataBase% &lt;/font&gt;&lt;/div&gt;
&lt;div&gt;&lt;font face="Courier New"&gt;&lt;/font&gt; &lt;/div&gt;
&lt;div&gt;&lt;font face="Courier New"&gt;@set PolicyName=CompanyID&lt;br /&gt;
@set PolicyVersion=1.0&lt;br /&gt;
BTSTask AddResource  /ApplicationName:%ApplicationName% /Type:System.BizTalk:Rules  /Overwrite /Name:%PolicyName% /Version:%PolicyVersion% /Server:%BizTalkDataBasesServer% /Database:%BizTalkConfigurationDataBase% &lt;/font&gt;&lt;/div&gt;
&lt;div&gt;&lt;font face="Courier New"&gt;&lt;/font&gt; &lt;/div&gt;
&lt;div&gt;&lt;font face="Courier New"&gt;@set PolicyName=PortOfUnloadingID&lt;br /&gt;
@set PolicyVersion=1.0&lt;br /&gt;
BTSTask AddResource  /ApplicationName:%ApplicationName% /Type:System.BizTalk:Rules  /Overwrite /Name:%PolicyName% /Version:%PolicyVersion% /Server:%BizTalkDataBasesServer% /Database:%BizTalkConfigurationDataBase% &lt;/font&gt;&lt;/div&gt;
&lt;div&gt;&lt;font face="Courier New"&gt;&lt;/font&gt; &lt;/div&gt;
&lt;div&gt;&lt;font face="Courier New"&gt;@set PolicyName=DocumentValidator&lt;br /&gt;
@set PolicyVersion=1.1&lt;br /&gt;
BTSTask AddResource  /ApplicationName:%ApplicationName% /Type:System.BizTalk:Rules  /Overwrite /Name:%PolicyName% /Version:%PolicyVersion% /Server:%BizTalkDataBasesServer% /Database:%BizTalkConfigurationDataBase% &lt;/font&gt;&lt;/div&gt;
&lt;div&gt;&lt;font face="Courier New"&gt;&lt;/font&gt; &lt;/div&gt;
&lt;div&gt;&lt;br /&gt;
&lt;font face="Courier New"&gt;@Time /T&lt;/font&gt;&lt;/div&gt;
&lt;div&gt;&lt;font face="Courier New"&gt;&lt;/font&gt; &lt;/div&gt;
&lt;div&gt;&lt;font face="Courier New"&gt;@rem call RestartBTS.bat&lt;/font&gt;&lt;/div&gt;
&lt;div&gt;&lt;font face="Courier New"&gt;&lt;/font&gt; &lt;/div&gt;
&lt;div&gt;&lt;font face="Courier New"&gt;pause&lt;/font&gt;&lt;/div&gt;
&lt;div&gt;&lt;font face="Courier New"&gt;&lt;/font&gt; &lt;/div&gt;
&lt;div&gt;&lt;br /&gt;
&lt;font face="Courier New"&gt;@rem ----------- Settings.bat ---------------------------------------------&lt;br /&gt;
@set MyShortSolutionName=MyShortSolutionName&lt;br /&gt;
@Set SolutionName=MyCompany.Domain.%MyShortSolutionName%&lt;br /&gt;
@set SolutionDir=C:\Solutions\%MyShortSolutionName%&lt;br /&gt;
@SET CurrentBuildPath=%SolutionDir%\Builds\Current&lt;br /&gt;
@SET BizTalkServer=BTS-06V&lt;br /&gt;
@SET BizTalkDataBasesServer=BTS-06V&lt;br /&gt;
@SET BizTalkConfigurationDataBase=BizTalkMgmtDb&lt;br /&gt;
@Set ApplicationName=%MyShortSolutionName%.MyApp&lt;br /&gt;
&lt;br /&gt;
&lt;/font&gt;&lt;hr style="width: 100%; height: 2px;" /&gt;
&lt;font face="Courier New"&gt;&lt;br /&gt;
&lt;/font&gt;&lt;/div&gt;
&lt;div&gt; &lt;/div&gt;&lt;p&gt;&lt;a href="http://www.pheedo.com/click.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=111316"&gt;&lt;img src="http://www.pheedo.com/img.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=111316" border="0"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;iframe src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;PageID=31016&amp;amp;SiteID=1" width=1 height=1 Marginwidth=0 Marginheight=0 Hspace=0 Vspace=0 Frameborder=0 Scrolling=No&gt;
&lt;script language='javascript1.1' src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Browser=NETSCAPE4&amp;amp;NoCache=True&amp;PageID=31016&amp;amp;SiteID=1"&gt;&lt;/script&gt;
&lt;noscript&gt;&lt;a href="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Click&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" target="_blank"&gt;
&lt;img src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" width="1" height="1" border="0"  alt=""&gt;&lt;/a&gt;
&lt;/noscript&gt;
&lt;/iframe&gt;
&lt;img src="http://geekswithblogs.net/LeonidGaneline/aggbug/111316.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Leonid Ganeline</dc:creator>
            <guid>http://geekswithblogs.net/LeonidGaneline/archive/2007/04/10/111316.aspx</guid>
            <pubDate>Tue, 10 Apr 2007 15:41:00 GMT</pubDate>
            <wfw:comment>http://geekswithblogs.net/LeonidGaneline/comments/111316.aspx</wfw:comment>
            <comments>http://geekswithblogs.net/LeonidGaneline/archive/2007/04/10/111316.aspx#feedback</comments>
            <slash:comments>3</slash:comments>
            <wfw:commentRss>http://geekswithblogs.net/LeonidGaneline/comments/commentRss/111316.aspx</wfw:commentRss>
            <trackback:ping>http://geekswithblogs.net/LeonidGaneline/services/trackbacks/111316.aspx</trackback:ping>
        </item>
        <item>
            <title>BizTalk: Anti-Patterns: Business Rule Engine</title>
            <link>http://geekswithblogs.net/LeonidGaneline/archive/2006/12/27/102156.aspx</link>
            <description>&lt;div&gt;Let's see one of the projects I've made with the Business Rule Engine from the Microsoft BizTalk tool set. &lt;br /&gt;
There are the EDI data in"very flexible format". The source partners fill up the fields of these documents by different applications and peoples. As a result the data are usually spread through the several fields if they filling application has a limit to the field size. &lt;br /&gt;
 &lt;br /&gt;
For example:&lt;br /&gt;
Good data:&lt;br /&gt;
&lt;div style="margin-left: 40px;"&gt;&lt;em&gt;N1*CN*YOUNG BAY INTERNATIONAL INC&lt;/em&gt;&lt;br /&gt;
&lt;em&gt;N3*2655 ST-JACQUES#101*MONTREAL QC H3J 1H8 CANADA&lt;/em&gt;&lt;br /&gt;
&lt;em&gt;N3*TEL:514-8121887 514-9313157&lt;/em&gt;&lt;br /&gt;
&lt;/div&gt;
 &lt;br /&gt;
 &lt;br /&gt;
Bad data:&lt;br /&gt;
&lt;div style="margin-left: 40px;"&gt;&lt;em&gt;N1*CN*AFS -VISA INTERNATIONAL (HK) LTD    SUITE NO.1 29/F SKYLINE T&lt;/em&gt;&lt;br /&gt;
&lt;em&gt;N3*OWER      39 WANG KWONG ROAD, KOWLO&lt;/em&gt;&lt;br /&gt;
&lt;em&gt;N3*ON BAY,   KOWLOON, HONG KONG&lt;/em&gt;&lt;br /&gt;
&lt;/div&gt;
 &lt;br /&gt;
The data are in the wrong fields; the data are spread through the several fields; etc.&lt;br /&gt;
 &lt;br /&gt;
I need to map the data to the into the local database. For example:&lt;br /&gt;
we've got the source data: "YOUNG BAY INTERNATIONAL INC", which can be mapped to several "YOUNG BAY"-like companies, depends of other source data. In our data base we have:&lt;br /&gt;
"YOUNG BAY INC"&lt;br /&gt;
"YOUNG BAY INT'L CO"&lt;br /&gt;
"YOUNG-BAY INTERNATIONAL "&lt;br /&gt;
...&lt;br /&gt;
plus the variation in the other source data as City, State, CountryCode, PostalCode, Address etc.&lt;br /&gt;
 &lt;/div&gt;
&lt;div&gt; &lt;/div&gt;
&lt;div&gt;This project is the good candidate to use BRE. The data in the input set has different relations (rules). Those rules tend to be constantly improved and modified. It is the ideal candidate to use BRE, isn't it? &lt;br /&gt;
We can process the data by BRE. We can easily develop and modify the sets of rules. &lt;br /&gt;
 &lt;br /&gt;
The project was implemented in two stages.&lt;br /&gt;
First was the "Unification of the data". It unified the punctuation, "Incorp" --&amp;gt; ""Inc", "Logictic" -&amp;gt; "Logistics", "HONGKONG" -&amp;gt; "HK", "U  S  A" -&amp;gt; "US", "H3J 1H8" -&amp;gt; "H3J1H8", etc. etc. etc. &lt;br /&gt;
The second stage was the "Company resolving". It took the unified data from the input documents and looked through the corporate data base to map the input data to the corporate data. The example is above.&lt;br /&gt;
 &lt;br /&gt;
This part was implemented with help of the BRE .&lt;br /&gt;
 The Rule Sets were implemented.  There were about forty rules.&lt;/div&gt;
&lt;div&gt; &lt;/div&gt;
&lt;div&gt;And from the start there were the big issues with performance. &lt;br /&gt;
Why? The most of the rules did not have the conditions with the simple boolean comparisons like "&amp;lt;Name_Compny&amp;gt; == "value1" but the resource consuming query to the data base. &lt;br /&gt;
In the BRE the MOST of the rule conditions are tested (invoked) at the start. (For explanation there is a great article by Charles Young &lt;a href="http://geekswithblogs.net/cyoung/articles/79500.aspx"&gt;http://geekswithblogs.net/cyoung/articles/79500.aspx&lt;/a&gt;) In my case near ALL forty data base queries hit the performance the system.&lt;br /&gt;
I did not need in all queries at the start. Then I separated the rules to stages. If the first set of rules did not get the result, the second set comes to the work, etc.&lt;br /&gt;
Sounds good? Let see. &lt;br /&gt;
One of the BRE technology advantage is a Rete networks (a Rete algorithm) (see &lt;a href="http://en.wikipedia.org/wiki/Rete_algorithm"&gt;http://en.wikipedia.org/wiki/Rete_algorithm&lt;/a&gt;). It gives us the capability to efficiently process the big or huge sets of data. The BRE takes care about the order of the tests in the rule set conditions. Moreover the BRE cached the fields of an XML document or the columns of a database table and when these data are accessed for the second time or later within the policy, the values are usually retrieved from the cache. However, when the members of a .NET object are accessed for the second time or later, the values are retrieved from the .NET object, and not from the cache. That means if I invoke the same "test" method from several rules, BRE do not cache the result of this method but each time re invoke the method. It was unfortunately my case. &lt;br /&gt;
User has few techniques to manage the order and I used the simplest. I added to each test (or stage) a flag which goes up after this test is ended. The conditions checked the flags. The down flags in the conditions prevented the heavy part of the condition from the start. Now the conditions were started in managed order. &lt;br /&gt;
 &lt;br /&gt;
Looks weird.&lt;br /&gt;
 &lt;br /&gt;
First of all, the BRE is used to separate the business logic to the independent layer to make it easy (easy to creating, modification, maintaining). &lt;br /&gt;
Did I gather the business logic in the rules? No. The main part of rules was remained in the database queries and the classes which wrapped those queries. The rules did only manage the invoking of these queries. If these layers were the same size then the layering give me improvement. The most of the logic was out of BRE Rules layer and easily could be implemented by .NET code. Maintaining the BRE infrastructure for such easy work as invoking the methods in my case was not a good choice.&lt;br /&gt;
 &lt;br /&gt;
Second. The BRE takes care about the order of the tests in the rule set conditions. It SHOULD take care of it, otherwise we throw away of this advantage of the Business Rule Engine. If we manage the rule set condition order, we stopped at the same point where we started. I mean now I used BRE, it was cool, but all the rule order processing was mine responsibility. And the most of my issues was to avoid the BRE most amazing feature.&lt;br /&gt;
 &lt;br /&gt;
If the BRE was managed the rule set condition order, the performance was bad.&lt;br /&gt;
If I managed the rule set condition order, why do I need the BRE?&lt;br /&gt;
 &lt;br /&gt;
After several modifications in the rules I've decides to redesign the project. I've created the simple class to manage the rules and got rid of the BRE artifacts.&lt;br /&gt;
Ufff... It was cool but in my case it was something different.&lt;br /&gt;
Now all staff is pretty simple and manageable.&lt;br /&gt;
You can tell me "Now you cannot use the BRE Composer as a User interface to modifying and improving the business layer logic." That's true. Now I cannot delegate the "rule-modification" job to the third party. If this is a requirement then the BRE and the Composer would be a good choice. &lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
&lt;strong&gt;&lt;font size="4"&gt;Conclusions ("Donts"):&lt;br /&gt;
&lt;/font&gt;&lt;/strong&gt; &lt;br /&gt;
1. If your rules have the resource-consuming conditions (predicates) be aware of non-efficient performance.&lt;br /&gt;
2. If your rules have the well-defined processing order, seems the BRE is not your choice. If you don't care about the rule processing order, the BRE could be useful.&lt;br /&gt;
3. If your rules have the values in the conditions retrieved from the .NET object be aware of non-efficient performance. &lt;br /&gt;
4. Rules should cover the biggest part of the business logic. If the rules have a lot of calls to the .NET classes think of redesign this project.&lt;/div&gt;
&lt;div&gt; &lt;/div&gt;
&lt;div&gt;&lt;hr style="width: 100%; height: 2px;" /&gt;
&lt;strong&gt;Be aware of the BRE:&lt;br /&gt;
&lt;/strong&gt;It is the tool for processing the specific data set with specific conditions. Not all data and not all business logic can be implemented efficiently with BRE.&lt;br /&gt;
Maybe it is not what exactly we can estimate from the product with such name. Now it is hardly a tool for the Business Analyst. It is the tool for software developers. And this is great tool! &lt;br /&gt;
I'm sure the next version would be much better from a developers point of view.&lt;br /&gt;
 &lt;br /&gt;
&lt;hr style="width: 100%; height: 2px;" /&gt;
&lt;strong&gt;Notes:&lt;br /&gt;
&lt;/strong&gt;* The other simple method to stage the rules is to separate the rules to different policies and chain these policies. This approach did not work well for my case because I mostly had to manage the order of the rules, not the stages, what leads to pack one rule to one policy. Each policy creates the persistence point in the orchestration. Maybe it would not hit the performance too hard in my case, I didn't try this. &lt;br /&gt;
 &lt;br /&gt;
* We can force the caching of the .NET objects but only programmatic. The Business Rule Composer tool does not expose this possibility.&lt;/div&gt;
&lt;div&gt; &lt;/div&gt;
&lt;div&gt;&lt;hr style="width: 100%; height: 2px;" /&gt;
&lt;/div&gt;&lt;p&gt;&lt;a href="http://www.pheedo.com/click.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=102156"&gt;&lt;img src="http://www.pheedo.com/img.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=102156" border="0"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;iframe src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;PageID=31016&amp;amp;SiteID=1" width=1 height=1 Marginwidth=0 Marginheight=0 Hspace=0 Vspace=0 Frameborder=0 Scrolling=No&gt;
&lt;script language='javascript1.1' src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Browser=NETSCAPE4&amp;amp;NoCache=True&amp;PageID=31016&amp;amp;SiteID=1"&gt;&lt;/script&gt;
&lt;noscript&gt;&lt;a href="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Click&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" target="_blank"&gt;
&lt;img src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" width="1" height="1" border="0"  alt=""&gt;&lt;/a&gt;
&lt;/noscript&gt;
&lt;/iframe&gt;
&lt;img src="http://geekswithblogs.net/LeonidGaneline/aggbug/102156.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Leonid Ganeline</dc:creator>
            <guid>http://geekswithblogs.net/LeonidGaneline/archive/2006/12/27/102156.aspx</guid>
            <pubDate>Thu, 28 Dec 2006 03:56:00 GMT</pubDate>
            <wfw:comment>http://geekswithblogs.net/LeonidGaneline/comments/102156.aspx</wfw:comment>
            <comments>http://geekswithblogs.net/LeonidGaneline/archive/2006/12/27/102156.aspx#feedback</comments>
            <wfw:commentRss>http://geekswithblogs.net/LeonidGaneline/comments/commentRss/102156.aspx</wfw:commentRss>
            <trackback:ping>http://geekswithblogs.net/LeonidGaneline/services/trackbacks/102156.aspx</trackback:ping>
        </item>
        <item>
            <title>BizTalk: Business Rule Engine: Don't use vocabulary in development</title>
            <link>http://geekswithblogs.net/LeonidGaneline/archive/2006/10/16/94245.aspx</link>
            <description>&lt;DIV&gt;&lt;STRONG&gt;BizTalk: Business Rule Engine:&lt;BR&gt;Don't use vocabulary in development!&lt;/STRONG&gt;&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;Why?&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;Because it gives you big headache and so little instead of.&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;Our typical work with the facts in the rules is compounded from the steps:&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;* Changing/Add fact in/to a rule (if fact is in the one of the tabs of Fact Explorer): Without vocabulary we change/add fact in a rule by drag-and-drop it from the Fact Explorer. With vocabulary we drag-and-drop a definition from the Fact Explorer. No difference.&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;* Changing/Add fact in/to a rule (if this fact is not in vocabulary):&lt;BR&gt;Without vocabulary we work as before. With vocabulary we create a new version of our vocabulary (we can not change the old version because it is published (we have to publish the vocabulary otherwise we can not use its facts in the rules)).&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;* Cut the old version of the vocabulary:&lt;BR&gt;In the rules we change all facts from the old version to the facts from the new version. If we have some facts in vocabulary with reference to it from some rule we can not delete the old version of vocabulary with this fact. (I know the free utility for this purpose but don't recommend it because I had the unpredictable behaviour of the rules after such automatic updates of the facts.)&lt;BR&gt;In the real work it looks like: OK. This rule is near finish. I create a rule set but it use several versions of the one vocabulary and I don't like it. I want to cut the old versions. (I don't like to deploy many versions of one vocabulary. It creates absolutely mess.) I have to manualy upgrade the facts, change old version to a new one, then delete old versions of the vocabulary. But... the vocabulary is "near" finish. Oops, I need change one more fact inside (and create one more version). It's always "near"...&lt;BR&gt;When I work with the rule I can cange and it, change it without creating a new rule version. But with vocabulary it is completely prohibited. I can use vocabulary and test it only after publishing ("freeze and use"). &lt;BR&gt;OK. I'm trying to separate one vocabulary to two. One is the "Stable", the second is "Mutable". It can make my life easy. Wow, how interesting. I was thinking the vocabulary helps me to keep in mind less entities, but now I have to create an additional infrastucture...&lt;BR&gt;BTW I don't understand why we can't freeze the vocabulary with policy together.&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;One more time.&lt;BR&gt;A new fact: Without vocabulary I drag-drop new fact to the rule.&lt;BR&gt;With vocabulary I have to:&lt;BR&gt;1. create a new version of the vocabulary.&lt;BR&gt;2. add a new fact to it. And it is NOT short way! I do not describe here the odds of this step.&lt;BR&gt;3. Save and Publish (and, maybe, Deploy) new version.&lt;BR&gt;4. drag-drop new fact from vocabulary.&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;Additional work:&lt;BR&gt;1. creating a definition in the vocabulary.&lt;BR&gt;2. changing the old definition in the rules on the new definition from the last version of vocabulary.&lt;BR&gt;3. managing versions of the vocabulary.&lt;BR&gt;4. in deployment: creating, deploying and managing the vocabulary.&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;Pro for Vocabularies:&lt;BR&gt;* short names of facts in the rules. But in the rules we do not see "very long names" (not like "xpath-names" in maps: "/*[local-name()='EDI' and namespace-uri()='http://VPA.EDI.Schemas.EDICanonical']/*[local-name()='VesselID' and namespace-uri()='']"), we see readable names as "VPA.EDI.Schemas.EDICanonical:EDI/VesselID". It is very "small pro".&lt;BR&gt;* readable names and formats for the facts. It is a good Pro for the end users. &lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;Conclusion: I can see only one case when a vocabulary worth all this additional headache: If we have very stable rule set in the production and we can give it to the end power users (BTW never seen this mythic user).&lt;BR&gt;In the real development never use vocabulary!&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;&lt;STRONG&gt;Some Ideas&lt;/STRONG&gt;&lt;/DIV&gt;
&lt;DIV&gt;
&lt;P class=MsoPlainText style="MARGIN: 0cm 0cm 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: 'MS Mincho'"&gt;ok&lt;?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoPlainText style="MARGIN: 0cm 0cm 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: 'MS Mincho'"&gt;I won't use the vocabularies now.&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoPlainText style="MARGIN: 0cm 0cm 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: 'MS Mincho'"&gt;Anyway the idea of the vocabulary is wonderful.&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoPlainText style="MARGIN: 0cm 0cm 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: 'MS Mincho'"&gt;In what conditions I'd rather like to use them?&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoPlainText style="MARGIN: 0cm 0cm 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: 'MS Mincho'"&gt;&amp;nbsp;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoPlainText style="MARGIN: 0cm 0cm 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: 'MS Mincho'"&gt;Lets talk.&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoPlainText style="MARGIN: 0cm 0cm 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: 'MS Mincho'"&gt;&amp;nbsp;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoPlainText style="MARGIN: 0cm 0cm 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: 'MS Mincho'"&gt;I'd like the vocabulary be in sync with a policy. That means the changes in a vocabulary should not mean the changes in the policy. Let changes in the policy occur by default. &lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoPlainText style="MARGIN: 0cm 0cm 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: 'MS Mincho'"&gt;But the vocabulary is the separate from the policies entity. It can be used by several policies simultaneously.&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoPlainText style="MARGIN: 0cm 0cm 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: 'MS Mincho'"&gt;Lets think about it. One of the solutions is this: &lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoPlainText style="MARGIN: 0cm 0cm 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: 'MS Mincho'"&gt;By default a vocabulary is the part of the policy (BTW In the BizTalk it is the part of the policy. When we deploy the policy, we deploy the vocabularies in use with this policy.). In the BR Composer it should be the branch under the Policy node. All operation under Policy: Save, Publish, Deploy, Undeploy should work under (Policy+Vocabulary)ver.xx entity as whole. In this case I don't care about versions of the definitions in the current policy they are always in sync.&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoPlainText style="MARGIN: 0cm 0cm 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: 'MS Mincho'"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;Lets save the current separate vocabularies, but call them "shared vocabulary". If somebody wants to use the shared vocabulary, why don't.&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;BR&gt;-- &lt;BR&gt;Regards,&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;-- &lt;BR&gt;Leonid Ganeline&lt;BR&gt;BizTalk Solution Developer&lt;BR&gt;&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;p&gt;&lt;a href="http://www.pheedo.com/click.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=94245"&gt;&lt;img src="http://www.pheedo.com/img.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=94245" border="0"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;iframe src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;PageID=31016&amp;amp;SiteID=1" width=1 height=1 Marginwidth=0 Marginheight=0 Hspace=0 Vspace=0 Frameborder=0 Scrolling=No&gt;
&lt;script language='javascript1.1' src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Browser=NETSCAPE4&amp;amp;NoCache=True&amp;PageID=31016&amp;amp;SiteID=1"&gt;&lt;/script&gt;
&lt;noscript&gt;&lt;a href="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Click&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" target="_blank"&gt;
&lt;img src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" width="1" height="1" border="0"  alt=""&gt;&lt;/a&gt;
&lt;/noscript&gt;
&lt;/iframe&gt;
&lt;img src="http://geekswithblogs.net/LeonidGaneline/aggbug/94245.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Leonid Ganeline</dc:creator>
            <guid>http://geekswithblogs.net/LeonidGaneline/archive/2006/10/16/94245.aspx</guid>
            <pubDate>Mon, 16 Oct 2006 19:09:00 GMT</pubDate>
            <wfw:comment>http://geekswithblogs.net/LeonidGaneline/comments/94245.aspx</wfw:comment>
            <comments>http://geekswithblogs.net/LeonidGaneline/archive/2006/10/16/94245.aspx#feedback</comments>
            <slash:comments>6</slash:comments>
            <wfw:commentRss>http://geekswithblogs.net/LeonidGaneline/comments/commentRss/94245.aspx</wfw:commentRss>
            <trackback:ping>http://geekswithblogs.net/LeonidGaneline/services/trackbacks/94245.aspx</trackback:ping>
        </item>
    </channel>
</rss>