Exploring Performance, Throttling and Latency Settings with the PowerShell Provider for BizTalk

One of the new features in BizTalk Server 2010 is a new UI that lets you modify a whole host of performance-related settings. Those settings apply to the BizTalk Group, Hosts or Host Instances.

This is a massive feature! Previously, one was required to either modify the registry or update records in the BizTalk Management Database to achieve the same results.

PowerShell Provider for BizTalk

As part of a recent update, I have added support for reading and writing those settings on the corresponding objects. For the time being, I have not added related CmdLets but the properties are directly accessible on the various artifacts.

For instance, use the following syntax, to explore all properties of the BizTalk Group, including those performance-related settings:

PS BizTalk:\> (Get-Item BizTalk:\) | Format-List *
PS BizTalk:\>

<

Modifying a single setting is just a matter of assigning a new value to the appropriate property:

PS BizTalk:\> $btsGroup = (Get-Item BizTalk:\)
PS BizTalk:\> $btsGroup.PerfCounterCacheRefreshInterval = 90
PS BizTalk:\>

In the current version, you can also export those settings to an XML file that you can re-import at a later time, which allows you to simplify you deployment and automation scripts.

PS BizTalk:\> $btsGroup = (Get-Item BizTalk:\)
PS BizTalk:\> $btsGroup.ExportSettings("C:\settings.xml")
PS BizTalk:\>

Note that such export file is created using the builtin BizTalk 2010 API. It can be directly imported back from the Administration Console UI.

Finally, it is possible to re-import such settings from an export file. You can import settings for the whole BizTalk platform, or selectively for a BizTalk Group, a single or several BizTalk Hosts and a single or several Host Instances. Use the ImportSettings method on the appropriate object:

PS BizTalk:\> $btsGroup = (Get-Item BizTalk:\)
PS BizTalk:\> # Import All Settings
PS BizTalk:\> $btsGroup.ImportSettings("C:\settings.xml")
PS BizTalk:\> # Import Group Settings
PS BizTalk:\> $btsGroup.ImportGroupSettings("C:\settings.xml")
PS BizTalk:\> # Import Single Host Settings
PS BizTalk:\> $btsHost = (Get-Item 'BizTalk:\Platform Settings\Hosts\BizTalkServerApplication')
PS BizTalk:\> $btsHost.ImportHostSettings("C:\settings.xml")
PS BizTalk:\>

I hope you’ll enjoy using this feature! As always, please leave feedback on the CodePlex project. I’m taking any constructive feedback very seriously.

This entry was posted in BizTalk, PowerShell. Bookmark the permalink.

One Response to Exploring Performance, Throttling and Latency Settings with the PowerShell Provider for BizTalk

  1. Pingback: PowerShell Provider updated for BizTalk Server 2013 and BizTalk Server 2013 R2 | A Technical Perspective

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s