BizTalk: Debugging: Why is it so difficult?

Sometimes in the BizTalk forums such questions appear.
"...I have been using event log to test variables. I was hoping there was a way to watch it process in VS like you can debug a forms app."

There is a difference in the usual app and in the "BizTalk app".
When you start usual app it is exactly this app and you could debug it. When you "start" the BizTalk app that could means *many* *instances* of this BizTalk app could works simultaneously.
With BizTalk you have an intermediate layer, the host. This host (actually it is a host instance but it doesn't matter for this case) manages the app *instances*. It could start many app instances simultaneously and then dehydrate, rehydrate, stop, abort them without our intervention.
Ideally we need to attach a debugger to exactly one app instance (which one?) or create a debugger working with many app instances simultaneously.
It is one of the source of the complexity of debugging the BizTalk apps.
BTW What is a BizTalk application at all?

Please, let me know, what do you think.

Print | posted on Thursday, October 9, 2008 2:12 PM


# re: BizTalk: Debugging: Why is it so difficult?

left by Yossi Dahan at 10/12/2008 11:49 PM Gravatar
I don't know Leonid - a ASMX or WCF service deployed on IIS are also service side code, which can run on a server farm and it's lifecycle managed by the IIS worker process, and still - you could use the debugger to attach to a *specific process* on a *specific machine* and debug.

I do think that, theoretically at least (obviously I don't know all the considerations of the BizTalk product group), it should be possible to attach to code that's running on the server side and, as a minimum, view it's state (local variables etc); in fact - you could do that (to some degree) from HAT, so it's definitely better.

I do think it is a shame that it is not possible to see more information about a running process and drill down to custom code when attaching (although that's possible when attaching from VS to the same process as well), and generally feel HAT is a bit, should we put this...lacking.

# re: BizTalk: Debugging: Why is it so difficult?

left by Leonid Ganeline at 10/13/2008 8:09 AM Gravatar
Thank you, Yossi!
I really appreciate your additions.

I think the difference is the Web-service is a C# or VB code, but BizTalk process uses proprietary XLang language and C# only as an intermediate code.
I don't mind (would be glad :) ) if we could debug this C# code.
I agree with you. To me HAT seems like in a "beta" version. To much information for the BizTalk development team and lack of information for the BizTalk application developer. Or this information should be digging up heavily.

# re: BizTalk: Debugging: Why is it so difficult?

left by Amareswari at 1/7/2011 3:12 PM Gravatar
While debugging ,for attaching which host I choose
the command : C:\Windows\System32\tasklist.exe
with argumnets : /svc /fi "imagename eq btsntsvc.exe
you can see Biztalk hosts and related PIDs, you can choose which host you want attach to debug from there
Post A Comment