Saturday, October 31, 2009

BizTalk Performance

Here are some cool videos, docs and ppts about BizTalk Performance Testing Guidance:

Videos:

BizTalk 2009 – End to end performance testing (1/2)

BizTalk 2009 – End to end performance testing (2/2)

DOCS:

Microsoft BizTalk Server Performance Optimization Guide

BizTalk Server Database Optimization

PPTS:

Microsoft BizTalk Server End-to-End Performance Testing Guidance

BizTalk Server 2009 VPC

We can download a BizTalk Server 2009 VPC Image from:

http://www.microsoft.com/downloads/details.aspx?FamilyID=ced208ef-d31e-4711-bc13-ac0227e80d88&DisplayLang=en

In this download, we get also a Hands-on Labs to test and practice BizTalk Server 2009.

Problem Enlisting SendPort 0xC00CE557

When we get "Could not enlist Send Port 'Port Name'. Exception from HRESULT: 0xC00CE557" error when we import a binding:



We have to check that Filter properties inside the binding file are correct.

HTTP Receive Location Errors

Here is a link with the errors and the solutions that a Http Receive Location we can get when we try to access it:

http://biztalkdev.com/blogs/paulwu/archive/2006/08/01/BtsHttpReceive.aspx

Also, we can get an Http 500 error, if we are using a incorrect version of the BtsHttpReceive.dll in our 32bit or 64bit environment.

Using Context Properties Inside a Map (ContextAccesorFunctoid)

In codeplex we can download a very cool functoid, that allows us to use properties from the message context inside a map.

We can get the functoid in this link:
http://contextaccessor.codeplex.com

And here are some links that show us how to use it:

http://blog.eliasen.dk/2009/04/01/TheContextAccessorFunctoidPartI.aspx
http://blog.eliasen.dk/2009/04/15/TheContextAccessorFunctoidPartII.aspx
http://blogdoc.biztalk247.com/article.aspx?page=7a512419-d763-49e9-9e68-f9c59ff406c3

Received a "System.NotImplementedException" in custom pipeline component

When testing our custom pipeline component, we could receive a System.NotImplementedException.

If we are using the Http adapter with our pipeline and we use the Data property from the Message.BodyPart, the error is because the Http adapter implements de Setter but not the Getter for this property.

In this case, we have to use the GetOriginalDataStream method, instead of Getter of Data property:

Stream myBodyStream = Message.BodyPart.Data (Incorrect)
Stream myBodyStream = Message.BodyPart.GetOriginalDataStream() (Correct)

Script to Update Receive/Send Pipelines

We can modify the receive and the send pipelines from an SQL script.

First of all, we need to know the pipeline Id value, from the BizTalkMgmtDb database:

select Id from dbo.bts_pipeline where [Name] = '<Pipeline Name>'

Then we can modify the pipeline from wichever send port or receive location:

update dbo.adm_ReceiveLocation set SendPipelineId = <Pipeline Id> where [Name] = '<Receive Location Name>'

update dbo.bts_sendport set nReceivePipelineId = <Pipeline Id> where [nvcName] = '<Send Port Name>'

The Messaging Engine failed to register an adapter

When we get this error:

"The Messaging Engine failed to register an adapter . Details: "Registering multiple adapter types within the same process is not a supported scenario. For e.g. HTTP and SOAP receive adapters cannot co-exist in the same process".

Probably we have at least two receive locations from different adapters in the same IIS AppPool.

We have to separate the receive locations from different adapters in different IIS application pools.

More information at:
http://technet.microsoft.com/en-us/library/aa577833(BTS.10).aspx

Any Element Validation Error

Sometimes we need to add to our schemas an Any Element node, because we don't know the content of this node.

If we don't want any validation over this node, we must change the value of the Process Contents property and set to Skip.

Here are the values allowed for this property:

http://msdn.microsoft.com/en-us/library/aa547371(BTS.10).aspx

Mock Http Reflector

Only for test purposes, if we want to test our orchestration with an HTTP send port, we can use this code:

http://bartdesmet.net/blogs/bart/archive/2007/02/22/httplistener-for-dummies-a-simple-http-request-reflector.aspx

We can return the response that we want and test our orchestration.

Wednesday, June 03, 2009

Low Latency BizTalk

Here are some link to achieve low latency in BizTalk Solutions:

http://threaddump.blogspot.com/2005/03/optimizing-biztalk-for-latency.html

SOAP Adapter Configuration and Tuning Parameters:
http://msdn.microsoft.com/en-us/library/aa560822.aspx

Configuration Parameters that Affect Adapter Performance
http://msdn.microsoft.com/en-us/library/aa561380.aspx

Optimizing BizTalk Server Performance
http://technet.microsoft.com/en-us/library/cc594552.aspx

FIX: Slow performance on startup when you process a high volume of messages through the SOAP adapter in BizTalk Server
http://support.microsoft.com/kb/886966

BizTalk 2006 SOAP Adapter (Web Service call) in Messaging Only Scenario
http://blogs.digitaldeposit.net/saravana/post/2006/12/20/BizTalk-2006-SOAP-Adapter-(Web-Service-call)-in-Messaging-Only-Scenario.aspx

Adding Custom SOAP Headers

1) Add a Property Schema to the solution:
2) The Target namespace of our property schema, should be http://schemas.microsoft.com/BizTalk/2003/SOAPHeader.
3) Add an element to this property schema, for example MyCustomSoapHeader. Set the Property Schema Base to MessageContextPropertyBase.
4) In orchestration, inside the Construct Message shape of the message that we send to web service, add a Message Assignement.
5) Inside Message Assignement, assign our custom soap header to the message context property: