<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-12742678</id><updated>2011-04-21T21:12:27.018-07:00</updated><title type='text'>BPINirvana</title><subtitle type='html'>InterOp, Web Services, Business Process Integration. anything that has to do with applications exchanging data on the wire or on wirelss :)</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://bpinirvana.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/12742678/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://bpinirvana.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Khaled Hnidk</name><uri>http://www.blogger.com/profile/13152785394246380117</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>10</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-12742678.post-115668014755105559</id><published>2006-08-27T04:53:00.000-07:00</published><updated>2006-08-27T05:02:27.560-07:00</updated><title type='text'>Back!</title><content type='html'>so it has been a very very long while since i put anything on this blog, but well things has been quite crazy :)&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;anyway, lately i have been doing alot of investment in WCF/WSE. things with regards to specs and definitly deep dive in WCF.&lt;br /&gt;&lt;br /&gt;i have been always one of those guys who had lots of problems with [WebMethod] framework. simply the fact that you don't create your interface sepratly as in you define it somewhere then consume or implement in fact you design &amp; implement your prog interface by tagging methods on a class with [WebMethod] !&lt;br /&gt;&lt;br /&gt;additionally (just a little example) you have no control over WSDL which is quite a shame cause there is alot of intersting stuff to be done on this front&lt;br /&gt;&lt;br /&gt;anyway the 2 combined factors created a mess of web services. with badly designed WSDL &amp; web services in general&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;got to admin: WSE team is the first from microsoft side to acknowlege the defect and fixed it in thier own implementation led by smart people like Yasser Shohod.  and it is simple you create interface following&lt;br /&gt;&lt;br /&gt;[WebServiceBinding(        Name = "StockService",        Namespace = "&lt;a href="http://stockservice.contoso.com/wse/samples"&gt;http://stockservice.contoso.com/wse/samples&lt;/a&gt;",        ConformsTo = WsiProfiles.BasicProfile1_1,        EmitConformanceClaims = true)]&lt;br /&gt;interface IStockService&lt;br /&gt;{&lt;br /&gt;//Operation goes here&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;then you create your service implementation&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;  [WebService(        Namespace = "&lt;a href="http://stockservice.contoso.com/wse/samples"&gt;http://stockservice.contoso.com/wse/samples&lt;/a&gt;")]    public class StockService : IStockService   &lt;br /&gt;{&lt;br /&gt;//SERVICE HERE&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;that was primarly aiming towards implementing services outside IIS scope.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;later on WCF took this further by using servicecontract terminilogy (very smart choice) and definitly instance managment.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;more on this on later posts&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/12742678-115668014755105559?l=bpinirvana.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://bpinirvana.blogspot.com/feeds/115668014755105559/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=12742678&amp;postID=115668014755105559' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/12742678/posts/default/115668014755105559'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/12742678/posts/default/115668014755105559'/><link rel='alternate' type='text/html' href='http://bpinirvana.blogspot.com/2006/08/back.html' title='Back!'/><author><name>Khaled Hnidk</name><uri>http://www.blogger.com/profile/13152785394246380117</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-12742678.post-112698183589215971</id><published>2005-09-17T11:21:00.000-07:00</published><updated>2005-09-17T11:30:35.896-07:00</updated><title type='text'>Nasty Serializer Bugs</title><content type='html'>Ok one day, you design your schema working those multi dimention arrays thinking if it works in your orchs it shouldln't be a problem anywhere else.&lt;br /&gt;&lt;br /&gt;the hard aquired experience is no, you gonna fall into a trap called serializer bugs :(&lt;br /&gt;&lt;br /&gt;.NET serialization though the most powerful tool currently existing it has some heckups, one of them is the multi-dimention. on win 2000 box you will get "File/assembly not found and some random name" on win2003 you will get something like "can not generate XXX class", some wacky error telling you nothing.&lt;br /&gt;&lt;br /&gt;the moral of the story:&lt;br /&gt;- Keep your schemas simple&lt;br /&gt;- Test them with Chris Sell's Serlization Compiler (&lt;a href="http://www.SellsBrothers.com"&gt;www.SellsBrothers.com&lt;/a&gt;)&lt;br /&gt;-  Read &lt;a href="http://msdn.microsoft.com/library/en-us/dnxmlnet/html/trblshtxsd.asp"&gt;http://msdn.microsoft.com/library/en-us/dnxmlnet/html/trblshtxsd.asp&lt;/a&gt;, and learn of it&lt;br /&gt;&lt;br /&gt;happy 'schema design' ;)&lt;br /&gt;&lt;br /&gt;Kal&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/12742678-112698183589215971?l=bpinirvana.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://bpinirvana.blogspot.com/feeds/112698183589215971/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=12742678&amp;postID=112698183589215971' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/12742678/posts/default/112698183589215971'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/12742678/posts/default/112698183589215971'/><link rel='alternate' type='text/html' href='http://bpinirvana.blogspot.com/2005/09/nasty-serializer-bugs.html' title='Nasty Serializer Bugs'/><author><name>Khaled Hnidk</name><uri>http://www.blogger.com/profile/13152785394246380117</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-12742678.post-112021097021813929</id><published>2005-07-01T02:32:00.000-07:00</published><updated>2005-07-01T02:42:50.223-07:00</updated><title type='text'>Configuration Data!</title><content type='html'>it has been kind slow the past couple of weeks, maybe because it is summer :)&lt;br /&gt;&lt;br /&gt;anyway today i am talking about configuration: first let us start with who consumes configuration&lt;br /&gt;&lt;br /&gt;- Adapters&lt;br /&gt;- Pipelines&lt;br /&gt;- Orchs&lt;br /&gt;&lt;br /&gt;let us start one by one&lt;br /&gt;Your &lt;strong&gt;adapters &lt;/strong&gt;will need to consume some configuration data, starting from debug flags to some processing related flags.  the first question is who will run your adapters is it BTS services or IIS or your own custom process:&lt;br /&gt;&lt;ul&gt;&lt;li&gt;if it's BTS: You  are left either with editing BTSNTSVC.EXE.CONFIG to have your configuration, but carefull not to mess BTS configuration. or you can use Enterprise Library Configuration Block which work just fine. &lt;/li&gt;&lt;li&gt;if it's IIS: Something like the SOAP or HTTP adapter, well alot of us neglects the fact that ASP.NET runtime will run our code (adapter in this case) which means youn can leaverge ASP.NET runtime configuration tools (Web.Config) or even use the HTTPContext classes. &lt;/li&gt;&lt;li&gt;if it is your process: well you can do whatever you want but a strong advice go for Configuration block it really comes handy, and hey it is free ;)&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;as for pipelines: well the same as the adapter really applies on pipelines. which is good because the same approch can be resued all over again. &lt;/p&gt;&lt;p&gt;finally the orchs: if it is simple configuration (Text fields) i stronglly recomment using Const members on exeternal classes since it is very fast however, beaware that .NET compilers replaces those with the actual text upon compiling  - that is a tip from a good guy i know :) - so if it is better using static properties as the compilers doesn't replace those. again if you have to save configuration you can edit BTSNTSVC.EXE.CONFIG or use the configuration block.&lt;/p&gt;&lt;p&gt;well that was just some thoughts that i did like to share with you.. hope they help.&lt;/p&gt;&lt;p&gt; &lt;/p&gt;&lt;p&gt;Kal&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/12742678-112021097021813929?l=bpinirvana.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://bpinirvana.blogspot.com/feeds/112021097021813929/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=12742678&amp;postID=112021097021813929' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/12742678/posts/default/112021097021813929'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/12742678/posts/default/112021097021813929'/><link rel='alternate' type='text/html' href='http://bpinirvana.blogspot.com/2005/07/configuration-data.html' title='Configuration Data!'/><author><name>Khaled Hnidk</name><uri>http://www.blogger.com/profile/13152785394246380117</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-12742678.post-111960366132929035</id><published>2005-06-24T02:00:00.000-07:00</published><updated>2005-06-24T02:16:03.870-07:00</updated><title type='text'>Tips for performance</title><content type='html'>1- Use promoted props only for routing and subscription evaluation, these ones are slow, if you want to use property inside an orch use distingueshed fields they are faster.&lt;br /&gt;&lt;br /&gt;2- Pipelines: don't use XMLDocument object to load the document instead use firehose style cusrors to parse the XML, keep these pipelines as fast as possible as they are the real perforamance bottlenecks &lt;br /&gt;&lt;br /&gt;3- Watch out for serialization: BTS serializes your process on various conditions, however you can control that read my "Fast BPI, Faster Than What?" blog entry for options.&lt;br /&gt;&lt;br /&gt;4- infact try not to use orchs :), yes if you can replace that with content based routing then do that. the idea is to pay the lowest perfomance cost possible. &lt;br /&gt;&lt;br /&gt;5- Watch out for parrlle shapes, they don't look as fast as you think. careful use them as possible. &lt;br /&gt;&lt;br /&gt;6- use external code carefuly, BTS in itself is a very fast engine (nice done). but the code you write my not be designed to be as fast so only do that when you need to &lt;br /&gt;&lt;br /&gt;7- and if you need to use statless objects for example static methods on classes.&lt;br /&gt;&lt;br /&gt;8- Maps: XLTS functiods are faster than external assmblies, need to say why?&lt;br /&gt;&lt;br /&gt;7- minimize the state you save: ok everything in an orch is a state, including variables messages correlation sets (ofcource scoped either by orch or by scope shapes) everything gets saved into SQL using serialization, so minimizing this will make BTS consume less memory and ofcource the call to SQL will be smaller. &lt;br /&gt;&lt;br /&gt;8- Use transactional carefully, compensating transaction are by nature slow&lt;br /&gt;&lt;br /&gt;9- use correlationsets carefully, currently i couldn't see anything slower than that in BTS 2004, the reason is calls to SQL either to put the subscription record or to evaluate it :(&lt;br /&gt;&lt;br /&gt;10- oh yes this one is VERY nice, use XMLRecieve pipleine in recieve ports, use passthru in sending, reason: unless you are depromiting properties back to the message then use passthru they are much faster, use XMLRecieve in recive because they promote the propties.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/12742678-111960366132929035?l=bpinirvana.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://bpinirvana.blogspot.com/feeds/111960366132929035/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=12742678&amp;postID=111960366132929035' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/12742678/posts/default/111960366132929035'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/12742678/posts/default/111960366132929035'/><link rel='alternate' type='text/html' href='http://bpinirvana.blogspot.com/2005/06/tips-for-performance.html' title='Tips for performance'/><author><name>Khaled Hnidk</name><uri>http://www.blogger.com/profile/13152785394246380117</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-12742678.post-111916430184324844</id><published>2005-06-18T23:54:00.000-07:00</published><updated>2005-06-18T23:58:50.680-07:00</updated><title type='text'>Did i start that Orch before?</title><content type='html'>Okay, &lt;br /&gt;&lt;br /&gt;&lt;br /&gt;So You want to know if you started this particular instance of an orch before or not; here’s the situation: you have a business process, upon reaching a certain condition you spawn off an orch, simple eh? Remind me of the old threading days however here is the challenge your business process is layed over in away that this condition might repeat itself, raises a good question.. have we started this orch before or not. In a server programming model oyou would have kept a handle for the thread or (app domain or process) somewhere in a static variable and always check it before starting it. &lt;br /&gt;&lt;br /&gt;&lt;br /&gt;However in BTS it is completely stateless, I hear the voice in my head (as in yours) saying dude save the state in the database some where, well looks like the perfect solution (the cost of one straight forward DB call isn’t really much after all). Come to think of it we do have a state DB by default (yes I mean this MsgBox DB), can we just use it and check against it. The answer is yes using &lt;br /&gt;&lt;br /&gt;- Direct DB access (DON’T DO THAT AT HOME style, again). &lt;br /&gt;- Using subscription engine! And that is where I am going to leverage on&lt;br /&gt;&lt;br /&gt;Anyone familiar with  BTS subscription viewer, that small utility that we use to debug our business processes shows us what orchs ports is waiting for what(and their correlations as well). Reflecting that tool showed that it is using Biztalk.RulesEngine assembly.. NIIICE!. We just need to get the same data dump filter it and check against it. &lt;br /&gt;&lt;br /&gt;Let us walkthrough the subscription viewer: it is an EXE application. &lt;br /&gt;Single window has a &lt;br /&gt;- Data-grid (displays the subscription record) &lt;br /&gt;- A tree view that shows the details of the subscription (which port, which web method name which correlation and it is value etc…).&lt;br /&gt;&lt;br /&gt;Filtering the code showed a single method with the name of LoadSubscriptions that loads all the subscription the code is like:&lt;br /&gt;&lt;br /&gt;public void LoadSubscriptions()&lt;br /&gt;{&lt;br /&gt;      this.m_Subscriptions.Clear();  // Clears the datagrd&lt;br /&gt;      this.PredicateLists.Nodes.Clear(); // clears the tree view&lt;br /&gt;      SubscriptionRuleStore store1 = new SubscriptionRuleStore("Subscription Store"); // connect to the store&lt;br /&gt;      this.m_rs = store1.GetRuleSet(new RuleSetInfo(this.m_GroupName, 0, 0)); // GroupName is always -&gt; = "BizTalk Group"; (in the CTOR of the form)&lt;br /&gt;      foreach (Rule rule1 in this.m_rs.Rules.Values) // enumerate the list – previous call is too slow!&lt;br /&gt;      {&lt;br /&gt;// Basiclly what is happening here is creating a data table contains all the subscription and binding the grid to it. &lt;br /&gt;            string text1;&lt;br /&gt;            DataRow row1 = this.m_Subscriptions.Tables["Subscriptions"].NewRow(); &lt;br /&gt;            row1["SubscriptionID"] = rule1.Name;&lt;br /&gt;            row1["Priority"] = rule1.Priority;&lt;br /&gt;            UserFunction function1 = (UserFunction) rule1.Actions[0];&lt;br /&gt;            ClassMemberBinding binding1 = (ClassMemberBinding) function1.Binding;&lt;br /&gt;            Constant constant1 = (Constant) binding1.Arguments[0];&lt;br /&gt;            row1["Name"] = constant1.Value.ToString();&lt;br /&gt;            constant1 = (Constant) binding1.Arguments[1];&lt;br /&gt;            if ((text1 = constant1.Value.ToString()) == null)&lt;br /&gt;            {&lt;br /&gt;                  goto Label_0186;&lt;br /&gt;            }&lt;br /&gt;            text1 = string.IsInterned(text1);&lt;br /&gt;            if (text1 != "3d7a3f58-4bfb-4593-b99e-c2a5dc35a3b2") // Some stuff are canceled from the view, my guess internal BTS pluming stuff&lt;br /&gt;            {&lt;br /&gt;                  if (text1 == "59f295b0-3123-416e-966b-a2c6d65ff8e6")&lt;br /&gt;                  {&lt;br /&gt;                        goto Label_0162;&lt;br /&gt;                  }&lt;br /&gt;                  if (text1 == "226fc6b9-0416-47a4-a8e8-4721f1db1a1b")&lt;br /&gt;                  {&lt;br /&gt;                        goto Label_0174;&lt;br /&gt;                  }&lt;br /&gt;                  goto Label_0186;&lt;br /&gt;            }&lt;br /&gt;            row1["ServiceType"] = "MSMQT";&lt;br /&gt;            goto Label_019D;&lt;br /&gt;      Label_0162:&lt;br /&gt;            row1["ServiceType"] = "EPM";&lt;br /&gt;            goto Label_019D;&lt;br /&gt;      Label_0174:&lt;br /&gt;            row1["ServiceType"] = "XLANG";&lt;br /&gt;            goto Label_019D;&lt;br /&gt;      Label_0186:&lt;br /&gt;            row1["ServiceType"] = constant1.Value.ToString();&lt;br /&gt;      Label_019D:&lt;br /&gt;            constant1 = (Constant) binding1.Arguments[2];&lt;br /&gt;            row1["ServiceID"] = constant1.Value.ToString();&lt;br /&gt;            constant1 = (Constant) binding1.Arguments[3];&lt;br /&gt;            row1["InstanceID"] = constant1.Value.ToString();&lt;br /&gt;            constant1 = (Constant) binding1.Arguments[4];&lt;br /&gt;            row1["PortID"] = constant1.Value.ToString();&lt;br /&gt;            constant1 = (Constant) binding1.Arguments[5];&lt;br /&gt;            if ((text1 = constant1.Value.ToString()) != null)&lt;br /&gt;            {&lt;br /&gt;                  text1 = string.IsInterned(text1);&lt;br /&gt;                  if (text1 != "0")&lt;br /&gt;                  {&lt;br /&gt;                        if (text1 == "1")&lt;br /&gt;                        {&lt;br /&gt;                              goto Label_029A;&lt;br /&gt;                        }&lt;br /&gt;                        if (text1 == "2")&lt;br /&gt;                        {&lt;br /&gt;                              goto Label_02AC;&lt;br /&gt;                        }&lt;br /&gt;                        if (text1 == "3")&lt;br /&gt;                        {&lt;br /&gt;                              goto Label_02BE;&lt;br /&gt;                        }&lt;br /&gt;                  }&lt;br /&gt;                  else&lt;br /&gt;                  {&lt;br /&gt;                        row1["Enabled"] = "Disabled";&lt;br /&gt;                  }&lt;br /&gt;            }&lt;br /&gt;            goto Label_02CE;&lt;br /&gt;      Label_029A:&lt;br /&gt;            row1["Enabled"] = "Enabled";&lt;br /&gt;            goto Label_02CE;&lt;br /&gt;      Label_02AC:&lt;br /&gt;            row1["Enabled"] = "Deactivated";&lt;br /&gt;            goto Label_02CE;&lt;br /&gt;      Label_02BE:&lt;br /&gt;            row1["Enabled"] = "AdminDeactivated";&lt;br /&gt;      Label_02CE:&lt;br /&gt;            constant1 = (Constant) binding1.Arguments[6];&lt;br /&gt;            row1["ApplicationName"] = constant1.Value.ToString();&lt;br /&gt;            this.m_Subscriptions.Tables["Subscriptions"].Rows.Add(row1);&lt;br /&gt;      }&lt;br /&gt;      if (this.m_rs.Rules.Count &gt; 0)&lt;br /&gt;      {&lt;br /&gt;            this.SubDataGrid.Select(0);&lt;br /&gt;            this.SubDataGrid.CurrentRowIndex = 0;&lt;br /&gt;            this.SubDataGrid_CurrentCellChanged(null, null);&lt;br /&gt;      }&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Okay the previous code load s the subscriptions but does nothing else, upon cell change on the grid it displays the detils of the subscription as &lt;br /&gt;&lt;br /&gt;this.PredicateLists.Nodes.Clear();&lt;br /&gt;      int num1 = 0;&lt;br /&gt;      int num2 = 0;&lt;br /&gt;      Rule rule1 = (Rule) this.m_rs.Rules[this.SubDataGrid[this.SubDataGrid.CurrentRowIndex, 1]];&lt;br /&gt;      if (rule1.Conditions is LogicalAnd)&lt;br /&gt;      {&lt;br /&gt;            this.PredicateLists.Nodes.Add(new TreeNode("AndGroup0"));&lt;br /&gt;            LogicalAnd and1 = (LogicalAnd) rule1.Conditions;&lt;br /&gt;            for (num1 = 0; num1 &lt; and1.Arguments.Count; num1++)&lt;br /&gt;            {&lt;br /&gt;                  this.PredicateLists.Nodes[0].Nodes.Add(this.GetPredicateDisplayString(and1.Arguments[num1]));&lt;br /&gt;            }&lt;br /&gt;      }&lt;br /&gt;      else if (rule1.Conditions is LogicalOr)&lt;br /&gt;      {&lt;br /&gt;            LogicalOr or1 = (LogicalOr) rule1.Conditions;&lt;br /&gt;            for (num1 = 0; num1 &lt; or1.Arguments.Count; num1++)&lt;br /&gt;            {&lt;br /&gt;                  this.PredicateLists.Nodes.Add(new TreeNode("AndGroup" + num1));&lt;br /&gt;                  if (or1.Arguments[num1] is LogicalAnd)&lt;br /&gt;                  {&lt;br /&gt;                        LogicalAnd and2 = (LogicalAnd) or1.Arguments[num1];&lt;br /&gt;                        for (num2 = 0; num2 &lt; and2.Arguments.Count; num2++)&lt;br /&gt;                        {&lt;br /&gt;                              this.PredicateLists.Nodes[num1].Nodes.Add(this.GetPredicateDisplayString(and2.Arguments[num2]));&lt;br /&gt;                        }&lt;br /&gt;                  }&lt;br /&gt;                  else&lt;br /&gt;                  {&lt;br /&gt;                        this.PredicateLists.Nodes[num1].Nodes.Add(this.GetPredicateDisplayString(or1.Arguments[num1]));&lt;br /&gt;                  }&lt;br /&gt;            }&lt;br /&gt;      }&lt;br /&gt;      else&lt;br /&gt;      {&lt;br /&gt;            this.PredicateLists.Nodes.Add(new TreeNode("AndGroup0"));&lt;br /&gt;            this.PredicateLists.Nodes[0].Nodes.Add(this.GetPredicateDisplayString(rule1.Conditions));&lt;br /&gt;      }&lt;br /&gt;      this.PredicateLists.ExpandAll();&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Cool eh? Well what you need to know is your subscription will always contain data, additions to what you have in mind, stuff that has to do with Port IDs. However if you know the correlation attribute name, value, orchestration name and assembly name  it is enough information that you can use to answer the question raised (did I start this one before or not).  Be aware you may have multiple subscription for the same correlation if it is being used so many times in your process on different ports so make sure that you filter using the correct information. &lt;br /&gt;&lt;br /&gt;Final words: &lt;br /&gt;- The subscription viewer in itself is a slow tool because it dumps  all the subscription. I spent sometime trying to find any way to filter the data rather than killing the database but couldn’t find any so far. I am sure there is since BTS is very fast evaluating messages against subscriptions. &lt;br /&gt;- SubscriptionRuleStore is not a supported by BizTalk so whatever you write here is write it at your own risk.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/12742678-111916430184324844?l=bpinirvana.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://bpinirvana.blogspot.com/feeds/111916430184324844/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=12742678&amp;postID=111916430184324844' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/12742678/posts/default/111916430184324844'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/12742678/posts/default/111916430184324844'/><link rel='alternate' type='text/html' href='http://bpinirvana.blogspot.com/2005/06/did-i-start-that-orch-before.html' title='Did i start that Orch before?'/><author><name>Khaled Hnidk</name><uri>http://www.blogger.com/profile/13152785394246380117</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-12742678.post-111710089758306758</id><published>2005-05-26T02:37:00.000-07:00</published><updated>2005-05-26T02:48:17.590-07:00</updated><title type='text'>Toying with those maps</title><content type='html'>So what i am trying to figure out or prove is XSLT maps are faster than standard BTS maps outputs, reason i believe so is XSLT maps will use standard .NET transformation classes which based on firehose cursor style to process XML messages&lt;br /&gt;&lt;br /&gt;however standard maps are basiclly XML document that BTS has a way to process, what i did is i reflected the code for a map that uses XSL and here is what i found&lt;br /&gt;[SchemaReference("LinkDev.BizTalk.Adapters.OracleStaticAdapter.Schemas.CommandExecuteRequest", typeof(CommandExecuteRequest)), SchemaReference("MinistryOfCommerce.eInvestor.BizTalk.Schemas.SuperApprovalSchema", typeof(SuperApprovalSchema))]&lt;br /&gt;public sealed class mapAppFeesSUperAppIn2ExecuteReq : TransformBase&lt;br /&gt;{&lt;br /&gt;      // Methods&lt;br /&gt;      public mapAppFeesSUperAppIn2ExecuteReq();&lt;br /&gt;&lt;br /&gt;      // Properties&lt;br /&gt;      public override string[] SourceSchemas { get; }&lt;br /&gt;      public override string[] TargetSchemas { get; }&lt;br /&gt;      public override string XmlContent { get; }&lt;br /&gt;      public override string XsltArgumentListContent { get; }&lt;br /&gt;&lt;br /&gt;      // Fields&lt;br /&gt;      private const SuperApprovalSchema _srcSchemaTypeReference0 = null;&lt;br /&gt;      private const string _strArgList = "&lt;ExtensionObjects /&gt;\n";&lt;br /&gt;      private const string _strMap = "&lt;xsl:stylesheet version=\"1.0\"  \nxmlns:xsl=\"http://www.w3.org/1999/XSL/Transform\"  \nxmlns:ns0=\"http://LinkDev.BizTalk.Adapters.OracleStaticAdapter.Schemas.CommandExecuteRequest\" \nxmlns:msxsl=\"urn:schemas-microsoft-com:xslt\" \nxmlns:user=\"http://MinistryOfCommerce/eInvestor/BizTalk/TransactionProcess/CustomEXSLT\"&gt; \n&lt;xsl:output method=\"xml\" omit-xml-declaration=\"yes\"/&gt; \n \n \n\t &lt;strong&gt;&lt;strong&gt;--- Rest of XSLT file that i used for the map&lt;/strong&gt;&lt;/strong&gt;";&lt;br /&gt;      private const string _strSrcSchemasList0 = "MinistryOfCommerce.eInvestor.BizTalk.Schemas.SuperApprovalSchema";&lt;br /&gt;      private const string _strTrgSchemasList0 = "LinkDev.BizTalk.Adapters.OracleStaticAdapter.Schemas.CommandExecuteRequest";&lt;br /&gt;      private const CommandExecuteRequest _trgSchemaTypeReference0 = null;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt; &lt;br /&gt;while trying to reflect a standard map i found: &lt;br /&gt;[SchemaReference("MinistryOfCommerce.eInvestor.BizTalk.Schemas.eInvestorResponseMessage", typeof(eInvestorResponseMessage)), SchemaReference("MinistryOfCommerce.eInvestor.BizTalk.Schemas.eInvestorTransactionMessage", typeof(eInvestorTransactionMessage))]&lt;br /&gt;public sealed class mapInternal2Response : TransformBase&lt;br /&gt;{&lt;br /&gt;      // Methods&lt;br /&gt;      public mapInternal2Response();&lt;br /&gt;&lt;br /&gt;      // Properties&lt;br /&gt;      public override string[] SourceSchemas { get; }&lt;br /&gt;      public override string[] TargetSchemas { get; }&lt;br /&gt;      public override string XmlContent { get; }&lt;br /&gt;      public override string XsltArgumentListContent { get; }&lt;br /&gt;&lt;br /&gt;      // Fields&lt;br /&gt;      private const eInvestorTransactionMessage _srcSchemaTypeReference0 = null;&lt;br /&gt;      private const string _strArgList = "&lt;ExtensionObjects /&gt;\n";&lt;br /&gt;      private const string _strMap = "&lt;?xml version=\"1.0\" encoding=\"UTF-16\"?&gt; \n&lt;xsl:stylesheet xmlns:xsl=\"http://www.w3.org/1999/XSL/Transform\" xmlns:msxsl=\"urn:schemas-microsoft-com:xslt\" xmlns:var=\"http://schemas.microsoft.com/BizTalk/2003/var\" exclude-result-prefixes=\"msxsl var s0 userCSharp\" version=\"1.0\" xmlns:s0=\"http://MinistryOfCommerce.eInvestor.Biztalk.Process.InternalSchemas.Transaction\" xmlns:ns0=\"http://MinistryOfCommerce.eInvestor.Biztalk.Schemas.eInvestorResponseMessage\" xmlns:userCSharp=\"http://schemas.microsoft.com/BizTalk/2003/userCSharp\"&gt; \n  &lt;xsl:output omit-xml-declaration=\"yes\" version=\"1.0\" method=\"xml\" /&gt; \n  &lt;xsl:template match=\"/\"&gt; \n    &lt;xsl:apply-templates select=\"/s0:Transaction\" /&gt; \n  &lt;/xsl:template&gt; \n  &lt;xsl:template match=\"/s0:Transaction\"&gt; \n    &lt;ns0:eInvestorResponseMessage&gt; \n      &lt;xsl:variable name=\"var:v1\" select=\"userCSharp:returnINtError()\" /&gt; \n      &lt;ReferenceNumber&gt; \n        &lt;xsl:value-of select=\"$var:v1\" /&gt; \n      &lt;/ReferenceNumber&gt; \n      &lt;xsl:variable name=\"var:v2\" select=\"userCSharp:returnErrorString()\" /&gt; \n      &lt;ErrorID&gt; \n        &lt;xsl:value-of select=\"$var:v2\" /&gt; \n      &lt;/ErrorID&gt; \n      &lt;xsl:variable name=\"var:v3\" select=\"userCSharp:returnErrorString()\" /&gt; \n      &lt;ErrorReason&gt; \n        &lt;xsl:value-of select=\"$var:v3\" /&gt; \n      &lt;/ErrorReason&gt; \n      &lt;xsl:variable name=\"var:v4\" select=\"userCSharp:returnErrorString()\" /&gt; \n      &lt;TokenID&gt; \n        &lt;xsl:value-of select=\"$var:v4\" /&gt; \n      &lt;/TokenID&gt; \n    &lt;/ns0:eInvestorResponseMessage&gt; \n  &lt;/xsl:template&gt; \n  &lt;msxsl:script language=\"C#\" implements-prefix=\"userCSharp\"&gt;&lt;![CDATA[\npublic int returnINtError() \n{ \n\treturn 0; \n}\n\npublic string returnErrorString() \n{ \n\treturn \"Error in processing\"; \n}\n\n\n]]&gt;&lt;/msxsl:script&gt; \n&lt;/xsl:stylesheet&gt;";&lt;br /&gt;      private const string _strSrcSchemasList0 = "MinistryOfCommerce.eInvestor.BizTalk.Schemas.eInvestorTransactionMessage";&lt;br /&gt;      private const string _strTrgSchemasList0 = "MinistryOfCommerce.eInvestor.BizTalk.Schemas.eInvestorResponseMessage";&lt;br /&gt;      private const eInvestorResponseMessage _trgSchemaTypeReference0 = null;&lt;br /&gt;}&lt;br /&gt; &lt;br /&gt;&lt;br /&gt;&lt;br /&gt;so conclusion so far are: &lt;br /&gt;- even standard BTS maps generates XSLT  and being pocessed slightly different check out those var:var statments. &lt;br /&gt;- I still belive that XSLTs are faster and they gave u more flixbility more on this now. &lt;br /&gt;- If i want to create a simple map i will use standard BTS map wizard, while if i want a complex (will be used alot) i will go for XSLT&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Kal&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/12742678-111710089758306758?l=bpinirvana.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://bpinirvana.blogspot.com/feeds/111710089758306758/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=12742678&amp;postID=111710089758306758' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/12742678/posts/default/111710089758306758'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/12742678/posts/default/111710089758306758'/><link rel='alternate' type='text/html' href='http://bpinirvana.blogspot.com/2005/05/toying-with-those-maps.html' title='Toying with those maps'/><author><name>Khaled Hnidk</name><uri>http://www.blogger.com/profile/13152785394246380117</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-12742678.post-111658550297880710</id><published>2005-05-20T03:37:00.000-07:00</published><updated>2005-05-21T05:11:41.143-07:00</updated><title type='text'>Fast BPI, Faster Than What?</title><content type='html'>Regular weekend cappuccino J trying to get thoughts straight for that blog entry, okay what I am talking about. I am talking about BTS 2004 Orchs performance and optimization.&lt;br /&gt;&lt;br /&gt;I happened to be in one of these projects where we are delivering an integrated “fully configurable” workflow, you know the drill external data store contains all the configuration data this configuration data affects your orchs in a couple of areas&lt;br /&gt;- Message process – should your workflow process a just received message or kick it back returning some business validation rule violation error – yeah those errors that you keep in Strings.cs or external resources files&lt;br /&gt;&lt;br /&gt;- Decisions shapes – should your orch do X or Y&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Anyway during the implementation I found out about a couple of interesting things that would&lt;br /&gt;&lt;br /&gt;- Make your life easier during the development&lt;br /&gt;- Let you answer questions from other techy’s/whoever telling you hey that is slow I can write C# code that would do better job and more importantly faster.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Development:&lt;br /&gt;As you have noticed developing orchs using VS.NET 2003 is nasty especially – That one is much, much better in BTS 2006 code named PathFinder as I have learned - if you are implementing a lot of ports and messages in/out. The reason behind that is GDI L. Somewhere in the designer it consumes a lot of memory I found out that:&lt;br /&gt;- Develop using Windows XP or 2003 it – the designer - is more optimized on them (don’t ask me why I am trying to find out why still)&lt;br /&gt;- If you have to do it on win 2000 then get that SP1 it really helps&lt;br /&gt;- Don’t connect to local SQL, Deployment and enlisting generates a lot of traffic on local SQL so why not using one of these big/ fat development servers instead of connecting locally&lt;br /&gt;- Always, always close port surface like:&lt;br /&gt;&lt;br /&gt;&lt;img src="http://www.geocities.com/khnidk/image1.GIF"&gt;&lt;br /&gt;&lt;br /&gt;Reason behind that is it really puts GDI @ ease to eliminate these lines connecting your shapes and ports&lt;br /&gt;&lt;br /&gt;- If you are using Virtual PC to do the good stuff, then put it – VMD files - on a different HDD if you are running on a tower pc or put it on USB 2 external HDD if you are running on a laptop – yes these works like a charm&lt;br /&gt;&lt;br /&gt;Runtime:&lt;br /&gt;Okay scaling up or out your servers is pretty straight forward, adding more servers and how to add them is published everywhere on MSDN and Microsoft web site. But what I am trying to introduce is ability to get these orchs to act faster and do more.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Let me tell you this the problem that might make your orchs slower isn’t executing code within the orchs it is the state maintenance, by that I mean the fact that BTS saves the orchs during execution so if things went wrong it can compensate, execute from last successful step or whatever you configure it.&lt;br /&gt;&lt;br /&gt;Most of the code generated out of orchs is maps call or send/receive calls the heavy calls – other than state maintenance is during sending or receiving (hence pipeline/adapters) can really damage your performance expectation but I am saving that talk for later blog entry.&lt;br /&gt;&lt;br /&gt;Before I go on I want to introduce to concepts related to orchs processing within BTS&lt;br /&gt;- Serialization: is done when BTS put a mark on your orch instance, think of it as the last successful action made during you’re your processing, this happens a lot in Send/Receive loops etc..&lt;br /&gt;o How it happens: BTS orch code genereated is just a .NET class that implements ISerializable interface or other seriliazation mechanism, during the execution BTS decides it needs to mark it, it serializes everything to the MSGBOX DB. And it doesn’t take anything out of BTS Host’s memory. Pretty smart stuff eh? J loved that one btw&lt;br /&gt;- Dehydration: is done when BTS decides ok this particular instance is not needed in the memory any more (happens in listen, delay, receive shapes – other than activation). Later on when BTS decides to awaken – hydrates – this instance based on message received, delay is over – those one are message also called timer messages- , more on that later on other blogs.&lt;br /&gt;o Ho it happens: it happens using serialization as well but this time BTS takes everything out of the host’s memory.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;As you have noticed both operations entails heavy calls to SQL stored procs, unfortunately you can not control dehydration process as it is totally controlled by BTS – which is good to tell you the truth – however the serialization process is controllable using few tricks.&lt;br /&gt;&lt;br /&gt;Btw I found this &lt;a href="http://groups.msn.com/BizTalkRocks/general.msnw?action=get_message&amp;mview=0&amp;amp;ID_Message=8&amp;LastModified=4675511469535796067"&gt;post&lt;/a&gt; to control the dehydration but it is don’t do it at home style&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Back to our talk, BTS never serializes scoped operations reason is message processing so scope shapes can be your best friend if you used them well:&lt;br /&gt;&lt;br /&gt;Consider the following picture: it is send receive shapes in a scope (BTS will not go to DB in scopes, I have tried atomics and none transactional none synchronized scopes and it works like a charm). This way you minimize calls to SQL hence faster processing.&lt;br /&gt;&lt;br /&gt;&lt;img src="http://www.geocities.com/khnidk/image2.GIF"/&gt;&lt;br /&gt;&lt;br /&gt;NOTE: doing that will not let BTS mark the execution so if it is failed somewhere in the middle of the scope it will start the execution before the scope. Hence do that carefully on top of my mind I can tell you&lt;br /&gt;- do that when there is no harm repeating the calls (like Update statements)&lt;br /&gt;- do that in loops if there is no harm repeating your loops starting the counter @ 0.&lt;br /&gt;- Do that if your adapters are transactional.&lt;br /&gt;- Don’t do that when your sending messages to external entities (you never trust how they process repeated messages)&lt;br /&gt;- Don’t do that during calls to web services (unless they implement some transactional mechanism).&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Other tips related to performance is parallel execution&lt;br /&gt;- No I am not saying use it, instead don’t use it in message processing. Use them if you are doing some execution that has nothing to do with sending or receiving message. Reason is using that will most probably require some synchronization shapes which hurts your performance. (in addition imagine the number of calls to SQL if you have a couple of branches that send/receive messages)&lt;br /&gt;&lt;br /&gt;If you want to test how many times BTS serializes your orch instances create a serializable class have it as amember variable in your orch and let it save counter for each time your serialization ctor called, then try with different shapes (loops receive delays and so on) promise, astonishment!&lt;br /&gt;&lt;br /&gt;I will keep this post short will stop here, later I will talk about messages/schemas I want to tell you about optimizing your schemas for performance (that will entails talking about pipelines)&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Feel free to communicate with me on &lt;a href="mailto:khnidk@gmail.com"&gt;khnidk@gmail.com&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Enjoy BPI,&lt;br /&gt;Kal&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/12742678-111658550297880710?l=bpinirvana.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://bpinirvana.blogspot.com/feeds/111658550297880710/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=12742678&amp;postID=111658550297880710' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/12742678/posts/default/111658550297880710'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/12742678/posts/default/111658550297880710'/><link rel='alternate' type='text/html' href='http://bpinirvana.blogspot.com/2005/05/fast-bpi-faster-than-what.html' title='Fast BPI, Faster Than What?'/><author><name>Khaled Hnidk</name><uri>http://www.blogger.com/profile/13152785394246380117</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-12742678.post-111613870617844026</id><published>2005-05-14T23:29:00.000-07:00</published><updated>2005-05-14T23:31:46.183-07:00</updated><title type='text'>BizTalk Map Tester</title><content type='html'>This tool test BizTalk maps (out of BTS assemblies), this one comes handy if you suspected that one of your maps isn't doing what it's supposed to do. without going to VS.NET&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.gotdotnet.com/Community/UserSamples/Details.aspx?SampleGuid=ac910d58-3cf3-4b01-8e56-79ea86aba2f3"&gt;http://www.gotdotnet.com/Community/UserSamples/Details.aspx?SampleGuid=ac910d58-3cf3-4b01-8e56-79ea86aba2f3&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Kal&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/12742678-111613870617844026?l=bpinirvana.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://bpinirvana.blogspot.com/feeds/111613870617844026/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=12742678&amp;postID=111613870617844026' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/12742678/posts/default/111613870617844026'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/12742678/posts/default/111613870617844026'/><link rel='alternate' type='text/html' href='http://bpinirvana.blogspot.com/2005/05/biztalk-map-tester.html' title='BizTalk Map Tester'/><author><name>Khaled Hnidk</name><uri>http://www.blogger.com/profile/13152785394246380117</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-12742678.post-111597935112415843</id><published>2005-05-13T02:18:00.000-07:00</published><updated>2005-05-13T03:18:13.063-07:00</updated><title type='text'>Deploy, Bind, Enlist &amp; Start. Need to say more?</title><content type='html'>&lt;span style="color:#ff0000;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:verdana;font-size:85%;"&gt;a very busy week; one of the biggest projects is getting to see the light, alot of tight deadlines and deliveries. anyway it is getting out which is good ;)&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:verdana;font-size:85%;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:verdana;font-size:85%;"&gt;Okay so now you decided i wonna go develop some BTS projects to do some functionlity - whatever it's for now- the first question you gonna ask yourself is how am i going to build/structure my solutions you have alot of stuff @ hand orchs maps schemas custom components and whatever that comes into picture there. below are so thoughts i found comes handy intime of needs &lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:verdana;font-size:85%;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:Verdana;font-size:85%;"&gt;Rules:&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:Verdana;font-size:85%;"&gt;- Keep your projects small as possible as it will affect the time it takes to deploy to BTS DBs&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:Verdana;font-size:85%;"&gt;- Keep Maps in seprate project those little devils really take alot of time to compile. though in size comparson BTS orch project produces bigger assemblies. &lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:Verdana;font-size:85%;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:verdana;font-size:85%;"&gt;&lt;strong&gt;BTS Solutions Structure:&lt;/strong&gt; &lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:verdana;font-size:85%;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:verdana;font-size:85%;"&gt;&lt;strong&gt;Solution 1:&lt;/strong&gt; Pipelines and thier helperss &amp; support components. &lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:verdana;font-size:85%;"&gt;&lt;strong&gt;Project A-&lt;/strong&gt; .NET Class Library: &lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:verdana;font-size:85%;"&gt;Contains pipleline components (GAC these components)&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:verdana;font-size:85%;"&gt;&lt;strong&gt;Project B-&lt;/strong&gt; .NET Class library:&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:verdana;font-size:85%;"&gt;Contains .NET classes that your pipleline components consume. &lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:verdana;font-size:85%;"&gt;&lt;strong&gt;Project C-&lt;/strong&gt; Pipelines:&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:verdana;font-size:85%;"&gt;Contains your BTS piplelines (this project will be GACed so you should strong name it)&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:verdana;font-size:85%;"&gt;&lt;strong&gt;Solution 2:&lt;/strong&gt; Buisness Process and thier helpers&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:verdana;font-size:85%;"&gt;&lt;strong&gt;Project A: &lt;/strong&gt;Schemas (Strong named as it goes into GAC). this project output will be referenced from almost everything(pipleline assmblers &amp;amp; disassmblers, orchs ...etc).&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:verdana;font-size:85%;"&gt;&lt;strong&gt;Project B:&lt;/strong&gt; Transform&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:verdana;font-size:85%;"&gt;Your Maps and thier XSLTs if your are using them (GACed as well)&lt;/span&gt;&lt;br /&gt;&lt;strong&gt;&lt;span style="font-family:verdana;font-size:85%;"&gt;Project C:&lt;/span&gt;&lt;/strong&gt;&lt;span style="font-family:verdana;font-size:85%;"&gt; Process&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:verdana;font-size:85%;"&gt;Your Process orchs &lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:verdana;font-size:85%;"&gt;&lt;strong&gt;Project D:&lt;/strong&gt; .NET class that you Business process consumes. (GACed as well)&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;You think your done? the answer is yes if you want just to start. but the real answer is no if you want to make your life is easier moving on&lt;br /&gt;&lt;br /&gt;Okay during the development a big percentage of time you will be doing Deployment, binding enlistment and starting.&lt;br /&gt;&lt;br /&gt;in to move things from Development environment to Staging Environment i would strongly recommend nAnt deployment with the help of this sample &lt;a href="http://www.traceofthought.com/misc/BT2004DeployWithNantDocs.doc"&gt;doc&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;However in to deploy things on your machine you need something easier to configure and very very user friendly.&lt;br /&gt;&lt;br /&gt;I have found that batch files are the best (faster and easier to maintain - remember that any code you write you will have to maintain and debug).&lt;br /&gt;&lt;br /&gt;here how they should look like (&amp; they should run in the following sequence):&lt;br /&gt;&lt;ul&gt;&lt;li&gt;&lt;strong&gt;Termination Exe(terminating any orch intances):&lt;/strong&gt;a good guy &lt;a href="mailto:sherif.elmeteny@link.net"&gt;Sherif ElMeteny&lt;/a&gt; developed an EXE that terminates any instance of orchs running on local BTS using WMI. Note &lt;u&gt;DON'T&lt;/u&gt; run this on production environment. (the exec is avaliable on my &lt;a href="http://www.gotdotnet.com/Workspaces/Workspace.aspx?id=47e1758d-7495-48ab-9599-bbc68b80754f"&gt;workspace&lt;/a&gt;). you can run the EXE using the following command: &lt;em&gt;BiztalkWMI.exe Terminate&lt;br /&gt;&lt;/em&gt;&lt;/li&gt;&lt;li&gt;&lt;strong&gt;Stopping Orch Batch: &lt;/strong&gt;this batch stops the running orchs on Local BTS. should look like&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;cscript /NoLogo StopOrch.vbs "Fully Qulified Orch Name" "Assembly Name" Unenlist&lt;/p&gt;&lt;p&gt;&lt;em&gt;Note: Keep StopOrch.vbs - found in BTS directory/SDK/Sampls/Admin/ in the same folder&lt;/em&gt;&lt;/p&gt;&lt;ul&gt;&lt;li&gt;&lt;strong&gt;Undeployment Batch&lt;/strong&gt;: undeploys certain assemblies: the batch should contains commands like &lt;/li&gt;&lt;/ul&gt;&lt;em&gt;BTSDEPLOY REMOVE NAME=&lt;span style="color:#ff0000;"&gt;&lt;assmbly&gt;&lt;/span&gt; VERSION=1.0.0.0 Culture=neutral PUBLICKEYTOKEN=XXXXX UNINSTALL=True LOG=BTS.undeploy.&lt;span style="color:#ff0000;"&gt;&lt;project&gt;&lt;/span&gt;&lt;span style="color:#ff0000;"&gt;.&lt;/span&gt;process.log &lt;/em&gt;&lt;br /&gt;&lt;br /&gt;BTSDEPLOY REMOVE NAME&lt;span style="color:#ff6666;"&gt;=&lt;assmbly&gt;&lt;/span&gt; VERSION=1.0.0.0 Culture=neutral PUBLICKEYTOKEN=XXXXX UNINSTALL=True LOG=BTS.undeploy.&lt;project&gt;.process.log&lt;br /&gt;&lt;br /&gt;BTSDEPLOY REMOVE NAME=&lt;span style="color:#ff0000;"&gt;&lt;assmbly&gt;&lt;/span&gt; VERSION=1.0.0.0 Culture=neutral PUBLICKEYTOKEN=XXXXX UNINSTALL=True LOG=BTS.undeploy.&lt;project&gt;.process.log&lt;br /&gt;&lt;br /&gt;&lt;ul&gt;&lt;li&gt;&lt;strong&gt;Deployment Batch&lt;/strong&gt;: deploys certain assemblies: the batch should contains commands like &lt;/li&gt;&lt;/ul&gt;&lt;p&gt;BTSDEPLOY DEPLOY ASSEMBLY="C:\Projects\BuildOut\ProjectNameSpace.Schemas.dll" INSTALL=True LOG=BTS.deploy.ProjectName.schema.log&lt;br /&gt;&lt;/p&gt;&lt;p&gt;BTSDEPLOY DEPLOY ASSEMBLY="&lt;span style="color:#ff0000;"&gt;C:\Projects\BuildOut\ProjectNameSpace.Transform.dll&lt;/span&gt;" INSTALL=True LOG=BTS.deploy.ProjectName.Transform.log&lt;/p&gt;&lt;p&gt;BTSDEPLOY DEPLOY ASSEMBLY="&lt;span style="color:#ff0000;"&gt;C:\Projects\BuildOut\ProjectNameSpace.Process.dll&lt;/span&gt;" INSTALL=True LOG=BTS.deploy.ProjectName.Process.log&lt;/p&gt;&lt;p&gt;BTSDEPLOY IMPORT BINDING="&lt;span style="color:#ff0000;"&gt;C:\Projects\BuildOut\PortBinding.xml&lt;/span&gt;" LOG=bts.deploy.Project.binding.log (this file is imported after the deployment using BTS deployment wizard)&lt;/p&gt;&lt;ul&gt;&lt;li&gt;&lt;strong&gt;Starting Orchs Batch&lt;/strong&gt;: this batch starts the orchs after a deployment: should look like&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;cscript /Nologo EnlistOrch.vbs "&lt;span style="color:#ff0000;"&gt;Orch Fully qualified name&lt;/span&gt;" "&lt;span style="color:#ff0000;"&gt;Assembly Name&lt;/span&gt;" Start&lt;/p&gt;&lt;p&gt;Note: Keep EnlistOrch.vbs - found in BTS directory/SDK/Sampls/Admin/ in the same folder&lt;/p&gt;&lt;p&gt;&lt;/p&gt;&lt;p&gt;&lt;/p&gt;&lt;p&gt;As you have noticed these batch files are easy to maintain and run on the development environmnt i have noticed that the best thing is to run them then go grap a coffee, that explains my too mainy coffee/smoking breaks ;)&lt;/p&gt;&lt;p&gt;anyway. one challenge is if you renamed a port and you tried to deploy using the old binding file you will get address confilcts, so there is a couple of &lt;a href="http://www.gotdotnet.com/Workspaces/Workspace.aspx?id=47e1758d-7495-48ab-9599-bbc68b80754f"&gt;VBs &lt;/a&gt;that i have developed that delets all sendports and all recieve ports. (needless to say don't run those on production environment)&lt;/p&gt;&lt;p&gt;I have published samples to these batchs on the workspace with the ability to add GAC DLLs as well. they might come handy as you have noticed&lt;/p&gt;&lt;p&gt;well, that was a long post! keep me posted with your comments and feedback, use my Gmail address (&lt;a href="mailto:khnidk@gmail.com"&gt;khnidk@gmail.com&lt;/a&gt;)&lt;/p&gt;&lt;p&gt;Enjoy Deployment :)&lt;/p&gt;&lt;p&gt;Kal&lt;/p&gt;&lt;p&gt;&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/12742678-111597935112415843?l=bpinirvana.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://bpinirvana.blogspot.com/feeds/111597935112415843/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=12742678&amp;postID=111597935112415843' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/12742678/posts/default/111597935112415843'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/12742678/posts/default/111597935112415843'/><link rel='alternate' type='text/html' href='http://bpinirvana.blogspot.com/2005/05/deploy-bind-enlist-start-need-to-say.html' title='Deploy, Bind, Enlist &amp; Start. Need to say more?'/><author><name>Khaled Hnidk</name><uri>http://www.blogger.com/profile/13152785394246380117</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-12742678.post-111557077900476164</id><published>2005-05-08T09:39:00.000-07:00</published><updated>2005-05-08T09:46:19.020-07:00</updated><title type='text'>Hey and Welcome</title><content type='html'>Hi,&lt;br /&gt;&lt;br /&gt;My name is Khaled Hnidk, Call me Kal as it is easier this way. I am a Technical Consultant working with LinkdotNET a regional - middle east -  ISP, based in cairo&lt;br /&gt;&lt;br /&gt;Since almost everybody i know have been pushing me around to get this blog up, i finally decided to get it done.&lt;br /&gt;&lt;br /&gt;I have been for working for some 10+ years as programmer and related jobs ;)&lt;br /&gt;&lt;br /&gt;next, What this blog is all about? it's about BPI - Business Process Integeration - using Microsoft Technologies. stuff like BizTalk Server, BizTalk related frameworks, SPS.. you name it.&lt;br /&gt;&lt;br /&gt;currently i own this gotdotnet &lt;a href="http://www.gotdotnet.com/Workspaces/Workspace.aspx?id=47e1758d-7495-48ab-9599-bbc68b80754f"&gt;work space&lt;/a&gt; which is about an Oracle Adapter for BizTalk Server 2004. yet i believe i have more to share with world :)&lt;br /&gt;&lt;br /&gt;I will be sending more posts about tips, tricks, thoughts and hard aquired experiences about BPI that hopefully would make your BPI experience a bit easier and definitly more fun.&lt;br /&gt;&lt;br /&gt;That is it for this one&lt;br /&gt;&lt;br /&gt;Kal&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/12742678-111557077900476164?l=bpinirvana.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://bpinirvana.blogspot.com/feeds/111557077900476164/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=12742678&amp;postID=111557077900476164' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/12742678/posts/default/111557077900476164'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/12742678/posts/default/111557077900476164'/><link rel='alternate' type='text/html' href='http://bpinirvana.blogspot.com/2005/05/hey-and-welcome.html' title='Hey and Welcome'/><author><name>Khaled Hnidk</name><uri>http://www.blogger.com/profile/13152785394246380117</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry></feed>
