Quantcast
Channel: TechNet Blogs
Viewing all articles
Browse latest Browse all 34890

June BizTalk Guru - Ron Phillips (El Bo) brings us "Monitoring and Automatically Starting Host Instances Via A Scheduled Task"

$
0
0

It's time for our first June TechNet Guru winner!

Ron Phillips (El Bo) is our BizTalk TechNet Guru for June! See the TechNet Guru Contributions for June 2013.

 

El Bo's avatar 

About El Bo: Native of the San Francisco Bay Area, attended U.C. Berkeley (History major, I learned to code in high school). Once long ago I was a dBase/Clipper developer, and was the lead developer of a commercial code generator (Smart Templates). Then a Visual Basic/SQL developer, and then starting in 2000 a BizTalk developer (yes, I really did use BizTalk 2000).

 

Here is El Bo's winning article:

BizTalk: Monitoring and Automatically Starting Host Instances Via A Scheduled Task

 

Here are all the June BizTalk winners:

Guru Award BizTalk Technical Guru - June 2013

Gold Award Winner

 

Ron PhillipsBizTalk: Monitoring and Automatically Starting Host Instances Via A Scheduled TaskMandi Ohlinger: "This is a very helpful script that users can implement now. "
Peter Laker: "Excellent article, loads of detail and nice format."
Ed Price: "Great introduction! I love how this incrementally takes you through the
process."

Silver Award Winner

 

Abhijit
Mahato
Implementation of Routing slip pattern using ESB Toolkit 2.1 and BizTalk ServerMandi Ohlinger: "Great example of using ESB! The screen shots are a nice addition."
Ed Price: "Great formatting with the different sections! The images help visually explain everything."
Peter Laker: "Nice tip with lots of detail"

Bronze Award Winner

 

Mohit
Gupta
Complex FlatFile Conversion using Biztalk schema and Map Peter Laker: "Details, code and images make this a great article"
Ed Price: "The code blocks are very helpful!"
Mandi Ohlinger: "Great FlatFile example. We need more of these."

 

Thanks to Ron, Abhijit, and Mohit! We had a great collection of articles for our first month for the BizTalk Technical Guru competition! And congrats to Ron! We'll feature your article in a variety of ways (including this blog post)! The four BizTalk contributions are here.

 

 

And here's an excerpt from the article:

 

Building the Sample

To start, you need to be able to query the BizTalk management database. WMI gives us an easy hook for this:

SetobjWMIService = GetObject("winmgmts://./root/MicrosoftBizTalkServer")

Now you can look around in the management database with SQL queries - well, really simple ones. Finding out what will and won't work requires some trial and error.  For example, our final script lets you provide a list of host names to check (rather than all of the hosts on the machine - there may be some where you want to sometimes take a host instance offline temporarily). So you would think we'd query the database for a specific host name. 

But that WHERE clause on the query just doesn't work, so we grab all of them and iterate through the list:

SetcolHostInstances = objWMIService.ExecQuery("Select * from MSBTS_HostInstance Where HostType=1 And
IsDisabled=False "
)

That gives us a collection of host instances. In our script, we iterate through that to find a particular one.

 

===================================

 

Read the rest here:

BizTalk: Monitoring and Automatically Starting Host Instances Via A Scheduled Task

 

Thanks to Ron for your great contribution to the TechNet Guru contest! You can read about all the June winners here: TechNet Guru Award Winners - June 2013

 

Also, for the July Guru competition, see TechNet Guru Contributions for July 2013.

 

Are you a Wiki Ninja? http://technet.com/wiki

   - Ninja Ed


Viewing all articles
Browse latest Browse all 34890

Trending Articles