Presentation is loading. Please wait.

Presentation is loading. Please wait.

Microsoft BizTalk Server End-to-End Performance Testing Guidance

Similar presentations


Presentation on theme: "Microsoft BizTalk Server End-to-End Performance Testing Guidance"— Presentation transcript:

1 Microsoft BizTalk Server End-to-End Performance Testing Guidance
4/5/ :57 PM Microsoft BizTalk Server End-to-End Performance Testing Guidance Ewan Fairweather & Paolo Salvatori BizTalk Customer Advisory Team Microsoft © 2007 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

2 Session Objectives Describe how we run BizTalk performance assessments
4/5/ :57 PM Session Objectives Describe how we run BizTalk performance assessments Demonstrate tools and techniques that can be used during a BizTalk performance assessment Introduce the BizTalk Server Performance Optimization Guide © 2005 Microsoft Corporation. All rights reserved. This presentation is for informational purposes only. Microsoft makes no warranties, express or implied, in this summary.

3 Session Agenda Assessing application performance Key learnings
BizTalk Server performance assessment Methodology Tools

4 Tuning the Microsoft Platform

5 Using LogParser To Generate KPIs For Your Results
Demo Example results spreadsheet from a recent performance lab

6 Session Agenda Assessing application performance Key learnings
BizTalk Server performance assessment Methodology Tools

7 Key Learnings Platform Tuning
Turn off hyperthreading Adjust Windows Server 2003 for best performance Use a separate disk for PAGEFILE Stop unnecessary services (for instance, Print Spooler) Defrag volumes hosting BizTalk dbs

8 Key Learnings Platform Tuning
Disable the SynAttackProtect feature Prevent antivirus scanning Networking Adjust TCP/IP parameters in the registry Use 1-gigabit networks Separate subnets for Mgmt, Data, and Messaging Tune NICs for performance Memory for packet buffering Offload processing to NIC if possible

9 Key Learnings Platform Tuning – CLR Hosting Threads
To prevent thread starvation, BizTalk needs enough threads allocated to the .NET thread pool Controlled by per host reg key HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\BTSSvc$hostname\CLR Hosting DWORD entry Default Value Recommended Value MaxIOThreads 20 100 MaxWorkerThreads 25 MinIOThreads 1 MinWorkerThreads 3 4 1 2

10 Key Learnings BizTalk Host Configuration
Split up the sending, receiving, processing, and tracking into multiple hosts This technique allows each host to: Have its own set of resources such as memory, handles, .NET thread pool Decreases the contention on the MessageBox Host Queue tables Avoid running too many host instances on the same box

11 Key Learnings SQL Performance
4/5/ :57 PM Key Learnings SQL Performance Isolate BizTalk data and transaction log files Pre-allocate space to prevent autogrowth at run time Create multiple data files of the same size, one for each available core on the SQL machine, for the TempDb Add filegroups and files to the BizTalkMsgBoxDb Scale up the SQL Server resources CPU, disk, memory Separate BizTalk Databases across servers Multiple MessageBox databases Configure DTA Purge and Archive job © 2005 Microsoft Corporation. All rights reserved. This presentation is for informational purposes only. Microsoft makes no warranties, express or implied, in this summary.

12 Key Learnings Low Latency
Internal message queue MaxReceiveInterval parameter 500 ms default BatchSize parameter Turn off global tracking Use inline sends 1 3 2

13 Key Learnings Orchestrations (1 of 2)
4/5/ :57 PM Key Learnings Orchestrations (1 of 2) Eliminate unnecessary persistence points Minimize the internal state/size Use the Call Orchestration shape for performance Asynchronous mechanisms give flexibility but require a MessageBox round trip Direct Bound Ports, Self-Correlating Ports and Start Orchestration shape Eliminate logical ports and use inline sends Prefer distinguished field over promoted properties Turn off unnecessary tracking: Message send and receive tracking Begin and end tracking shape Define a performance counter for each orchestration type © 2005 Microsoft Corporation. All rights reserved. This presentation is for informational purposes only. Microsoft makes no warranties, express or implied, in this summary.

14 Key Learnings Orchestrations (2 of 2)
Avoid using XmlDocument for processing large messages The memory amount required to load an XMLDocument is up to 10 times the actual size of the message Instead use one the following techniques: // Use an XmlReader object to read the content of the message part using (XmlReader reader =(XmlReader)xlangMessage[0].RetrieveAs(typeof(XmlReader))) { ... } // Retrieve the content of the message part as a string using (string message =(XmlReader)xlangMessage[0].RetrieveAs(typeof(string))) // Deserialize the content of the message part to an instance of a custom .NET class using (RequestClass request =(XmlReader)xlangMessage[0].RetrieveAs(typeof(RequestClass))) 1 2 3

15 Key Learnings Pipelines (1 of 2)
Use PassThruReceive and PassThruTransmit pipelines whenever possible Avoid loading the entire document into memory using an XmlDocument object Use a streaming approach instead If you need to read the value of specific nodes inside an XML message part, do not use the SelectSingleNode method exposed by the XmlDocument class Use an instance of the XPathReader class contained in the Microsoft.BizTalk.XPathReader.dll assembly Use an instance of XPathMutatorStream class contained in the Microsoft.BizTalk.Streaming.dll if you need to read and eventually change the value of one or more elements.

16 Key Learnings Pipelines (2 of 2)
Use an instance of the VirtualStream class (Microsoft.BizTalk.Streaming.dll) when reading a large message Promote items to the message context only if you need them for: Message Routing (Orchestrations, Send Ports) Demotion of message context properties (Send Ports) “Write” to the context instead of “Promote” Use the IPipelineContext.ResourceTracker to track and dispose non-CLR resources Instrument your source code to make your components simple to debug Avoid ordered delivery and transaction support

17 Optimizing BizTalk Memory Usage
Demo Streaming techniques that can be used in pipelines

18 WCF Adapters Whenever possible, use one of the following WCF-* Adapters. WCF-NetTcp Adapter WCF-Custom Adapter + CustomBinding with the binaryMessageEncoder and tcpTransport Binding Elements. Add the serviceThrottling service behavior to a WCF-Custom Receive Location and use the following settings: Send Side (BizTalk Send Port): Parameter Default Suggested tcpTransport->ConnectionPoolSettings->maxOutboundConnectionsPerEndpoint 1 try changing to 20 tcpTransport->maxPendingAccepts tcpTransport->maxPendingConnections 10 tcpTransport->listenBacklog Receive Side (BizTalk Receive Location): Parameter Default Suggested tcpTransport->maxPendingAccepts 1 try changing to 20 tcpTransport->maxPendingConnections 10 try changing to 200 tcpTransport->listenBacklog Parameter Default Suggested serviceThrottling->maxConcurrentCalls 16 try changing to 20 serviceThrottling->maxConcurrentSessions 10 serviceThrottling->maxConcurrentInstances - leave the default

19 Optimizing WCF for performance
WCF Adapter Demo Optimizing WCF for performance

20 Session Agenda Assessing application performance Key learnings
BizTalk Server performance assessment Methodology Tools

21 BizTalk Server Performance Optimization Guide
Announcing MSDN

22 Assessing Application Performance
The usual story We all know testing is important for every solution Testing is neglected This is a problem Solutions using BizTalk tend to be business critical and tolerate little downtime Poor testing increases the risk profile of your project This runs the risk of huge technical and political problems

23 Effective testing reduces your project risk
Minimize Project Risk Unit testing Functional testing Integration testing User acceptance testing Disaster recovery testing/dry runs Overload testing Performance assessment Effective testing reduces your project risk

24 Session Agenda Assessing application performance Key learnings
BizTalk Server performance assessment Methodology Tools

25 BizTalk Performance Assessment
An end to end process with a set of goals and objectives Occurs over a set period of time It requires a team of individuals with the right skill sets to “tune the stack” Iterative knowledge transfer process Optimize Operate Design & Deliver POC Performance Assessment Pre-Live Performance Assessment Post-Live Performance Assessment

26

27 Scope Engagement Summary
Determine resource requirements What scenarios are you testing What technologies are involved What adapters are needed SAN requirements 32 bit vs. 64 bit Other requirements Throughput Latency Document all information! Guidelines, Goals, Constraints, etc. Staff the right people

28 Scope Defining Goals Provide objectives and success criteria for the lab Goals should cover Performance metrics Throughput, Latency Roles and Responsibilities Deliverables Define any constraints Is hardware fixed? Scale up/out BizTalk/SQL Can third party systems be scaled out? Web servers, MQ Series, Custom DB’s

29 Scope Defining Goals (Example)
Objective Measure the Maximum Sustainable Throughput (MST) for the given use cases with different hardware configurations. Test Case 1 Messaging-Only scenario Throughput : 50 messages/sec sustainable Latency: response time < 2 sec for 90% of messages Test Case 2 Payment service BizTalk orchestration Throughput : 3.6 million messages within an 8 hour period (125 messages/second) Latency : N/A

30 Scope Logical and Physical Architecture
1 2 3 4

31 Plan Determining Resource Requirements
Timeline 2 weeks of preparation time 1 week per test case 1 week to document findings SMEs required MQSeries, SQL Server, IIS, SAN Specialist Hardware request SAN Storage (HBA, Luns), Networking, Clustering Lab space Appropriate space, whiteboard, projector, security of room

32 Plan Sample Timeline 6 1 2 3 4 5

33 Prepare Detailed Solution Design Code complete Invest in test assets
Build/Deploy MSBUILD, MSI, BTSTask, Scripts Functional test BizUnit, Visual Studio Load test Loadgen, Visual Studio

34 Building The Lab Environment Installation and Configuration
Infrastructure RAID10/0+1? Databases and logs separated Database autogrowth Virus scanning software Third party systems Non-default values, scale-out options BizTalk Host configuration Message tracking Adapter configuration

35 Building The Lab Environment
Performance monitoring Deployment MSBuild, BTSTask, MSI Functional testing Validate automated load test Document Solution Performance Baseline Latency Throughput Spool depth etc

36 Executing the Performance Lab Assessment High Level Flow
Run automated test BizUnit, VSTS, LoadGen Document results KPIs, Check after every run Tuning for performance One modification at a time Perform platform modifications

37 Session Agenda Assessing application performance Key learnings
BizTalk Server performance assessment Methodology Tools

38 Helpful Tools BizTalk BPA 1.2 PerfMon BizTalk LoadGen BizUnit Log Man
4/5/ :57 PM Helpful Tools BizTalk BPA 1.2 PerfMon BizTalk LoadGen BizUnit Log Man Relog Log Parser PAL SQLIO BizTalk Orchestration Profiler © 2005 Microsoft Corporation. All rights reserved. This presentation is for informational purposes only. Microsoft makes no warranties, express or implied, in this summary.

39 Related Content MSDN Guidance BizTalk Customer Advisory Team Site
4/5/2017 Related Content MSDN Guidance Microsoft BizTalk Server Performance Optimization Guide Microsoft BizTalk Server Operations Guide BizTalk Server 2006 R2 Hyper-V Guide BizTalk Customer Advisory Team Site © 2008 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION. 39

40 Resources Troubleshooting MessageBox Latency Issues
BizTalk Server 2006: Managing a Successful Performance Lab Scaling Your Solutions Configuration Parameters that Affect Adapter Performance Persistence and the Orchestration Engine Troubleshooting MessageBox Latency Issues Performance Tips and Tricks Rule Engine Configuration and Tuning Parameters Performance Considerations When Using the Rule Engine

41 Filegroup – Resources BizTalk Server Database Optimization
4/5/ :57 PM Filegroup – Resources BizTalk Server Database Optimization Understanding Files and Filegroups How to: Add Data or Log Files to a Database (SQL Server Management Studio) How to: Move an Existing Index to a Different Filegroup (SQL Server Management Studio) Physical Database Files and Filegroups Working with tempdb in SQL Server 2005 Optimizing Server Performance Using I/O Configuration Options © 2005 Microsoft Corporation. All rights reserved. This presentation is for informational purposes only. Microsoft makes no warranties, express or implied, in this summary.

42 4/5/ :57 PM MQ Adapter Resources HOW TO: Set Up and Test the BizTalk Adapter for MQSeries BizTalk Adapter for WebSphere MQ © 2005 Microsoft Corporation. All rights reserved. This presentation is for informational purposes only. Microsoft makes no warranties, express or implied, in this summary.

43 Q & A

44 4/5/ :57 PM © 2008 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION. © 2007 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.


Download ppt "Microsoft BizTalk Server End-to-End Performance Testing Guidance"

Similar presentations


Ads by Google