We’ll I just spent about three hours tonight fighting with this issue, so I thought I’d post about it to hopefully save someone else from having to go through this.
I was trying to run a couple of samples from the ESB and I noticed that whenever I used an example that had to use an orchestration, I received the following error in my event log
Event Type: Warning
Event Source: BizTalk Server 2006
Event Category: BizTalk Server 2006
Event ID: 5410
Time: 4:08:39 PM
An error occurred that requires the BizTalk service to terminate. The most common causes are the following:
1) An unexpected out of memory error.
2) An inability to connect or a loss of connectivity to one of the BizTalk databases.
The service will shutdown and auto-restart in 1 minute. If the problematic database remains unavailable, this cycle will repeat.
Error message: Exception has been thrown by the target of an invocation.
Error source: mscorlib
My host instance would then shut down and try to restart itself every minute. Each retry would fail with this same error. I also ended up with a running service instance in the admin console that I couldn’t terminate.
Each time I sent another message, I would have to manually clean these left over instances from the DB before I could restart the host instance successfully. I finally noticed that this error was only occurring whenever a component in my “In-proc” host instance tried to run. Base on this I tracked the issue down the btsntsvc.exe.config file that we were suppose to edit during install. I had forgotten to remove the “[path]” place holder that is in the <ConfigurationFile> tag. We were suppose to replace this with the actual path to the Microsoft.Practices.ESB.PipelineComponents.config file. (I’ve did not have this step in my install checklists, so I have since added it). I realized that the AppDomains were not loading correctly and this caused my errors in every orchestration in that tried to run in that AppDomain.
This is what I had left in my config file:
As I said, I had forgotten to replace the [path] place holder. Anyways, I put in the proper path and I expected this to correct the situation, but I kept getting the same annoying error. After another hour of frustrated debugging, I realized that I had entered the config data like this:
You’ll notice that I had put line breaks before and after the path and filename. It was these dam line break that were causing the problem. I took them out and and used this:
Everything worked fine and the issues are gone.
I’ve seen a number of people asking about this on codeplex and other locations, so double check your settings and avoid the headaches.
Cheers and keep on BizTalking…