Friday 13 February 2009

C# Generics works with BizTalk Server 2009 (Beta) :)

I have tried yesterday and it worked.  I am really one of the happiest persons to have C# Generics support in BizTalk.

Though Generics was introduced in Version 2.0 of C# and CLR, BizTalk till its version 2006 R2 doesn't support it. But now the story has changed. Yes, BizTalk Server 2009-Beta can support C# helper class with typed parameters i.e. Generics.

In the BizTalk Server version till 2006 R2, though we can't use the C# helper class which has Generics defined in it, we can utilise them indirectly by creating a wrapper class around them. By making this way, we can still abide the rules of BizTalk Server i.e. of not exposing the class with Generics in it directly. But now in BizTalk Server 2009 Beta, we don't have to search for any workaround for using Generics.

Lets see a real time example where we will use C# Generics with BizTalk. I have a database table called "Employee" which contains Employee details (obviously). And as part of the message processing in BizTalk I have to retrieve the Employee name for the given Employee ID. So I'll use a C# helper class to retrieve the EmployeeName for the EmployeeID which will be passed in as a input parameter to a method in it. I have to design the C# helper project in a object-oriented way something like

image

In the EmployeesDataProvider class, I have defined the Generics as..

public  List<Employee> employeeList = new List<Employee>();

to populate it with the result of "select * from Employee" then I'll add this to cache. So next time I'll populate the "employeeList" only if the cache is NULL. Thus avoids the database trips. And use Generics search functionality to get the result from the "employeeList" collection as..

Employee cusTemp = employeeList.Find(delegate(Employee _cus)
           {
               if (_cus.EmployeeID == strEmployeeID)
               {
                   return true;

               }
               return false;
           });

           if (cusTemp != null)
           {
               ret = cusTemp.EmployeeName.ToString();
           }

So the functionality of my helper class is:

Build the EmployeesList (typed class with Generics)from database if its not in the cache / other wise use the cached employee list and use the Generics's Find method to get the EmployeeName for the given EmployeeID.

Now in to BizTalk Server (till 2006 R2), inside the Orchestration's expression shape you may not be able to initiate the EmployeesDataProvider class. Reason being, this class has got the "Generics" type declaration. But now, the same works in BizTalk Sever 2009. Here you can see in BizTalk Server 2009-Beta, the class containing Generics recognised.

GenericsWorking

Download source code for "Generics in BizTalk Server 2009": http://cid-01845bf64da73117.skydrive.live.com/self.aspx/INDWAY-Integration%20Services/TryGenerics.zip

Thanks to Connected Systems for providing us this feature.

 

Cheers

M.R.ASHWINPRABHU

Friday 6 February 2009

BizTalk poster updated for BizTalk Server 2009

Microsoft technical editors have updated the BizTalk Server poster for their new BizTalk Server 2009.

http://blogs.msdn.com/nabeelp/archive/2009/02/04/biztalk-posters-updated-for-biztalk-2009.aspx

BizTalk Server 2004: Mainstream support expires soon

Microsoft's mainstream support for BizTalk Server 2004 applications is expiring on 14/07/2009. But the extended support is available till 08/07/2014. In the extended support phase

  • Microsoft will not provide new non-security hotfixes.For those who require new non-security hotfixes during the Extended Support phase, they have to enrol themselves to the Extended Hotfix Support (EHS).
  • “No-charge” support options are no longer available.This means that customers will need to open paid support cases (such as Premier, Pro or Pay Per Incident cases) to obtain support for their product.For Premier and Pro customers who already open paid cases with Microsoft will notice little difference in the support during extended support phase.
Support Provided

Till 14/07/2009(Mainstream support)

Till 08/07/2014(Extended Support )

Paid support (per-incident, per hour, and others)

Yes

Yes

Security update support

Yes

Yes

Non-security hotfix support

Yes

Requires extended hotfix agreement, purchased within 90 days of mainstream support ending.

No-charge incident support

Yes

No

Warranty claims

Yes

No

Design changes and feature requests

Yes

No

Product-specific information that is available by using the online Microsoft Knowledge Base

Yes

Yes

Product-specific information that is available by using the Support site at Microsoft Help and Support to find answers to technical questions

Yes

Yes

BizTalk Server - Product Life cycle: http://support.microsoft.com/lifecycle/search/default.aspx?sort=PN&alpha=BizTalk+Server+2004&Filter=FilterNO

Microsoft is scheduled to release BizTalk Server 2009 by later this year (Its beta is already available for public:http://indway-is.blogspot.com/2008/12/biztalk-server-2009-beta-for-public.html). So if you plan to migrate your BizTalk server 2004 application, its advisable to wait for some time till the release of 2009 and migrate to 2009 to utilise the longer Microsoft support. And there is no direct upgrade path from BizTalk Server 2004 to BizTalk Server 2009. BizTalk server 2009 supports direct upgrade only from 2006 or 2006 R2.

Cheers

M.R.ASHWINPRABHU