Biztalk Direct Binding Messaging error
A few months ago I worked on a medium-size Biztalk project. I’ll depict in a few words the big picture of the application architecture in order to understand the context. The application backend was based entirely on Biztalk. The reason was all the Biztalk “poetry”: reliability, scalability, availability, asynchronous processing… the rich customer ready to pay for a Biztalk solution. The backend was designed to have two layers: one that exposes common and granular services specific to the business domain, the other one was thought to be specific to the applications that will consume the services. The services layer has an orchestration for each service it exposes.
The communication between the two layers was implemented with the Direct Binding mechanism to have a low coupling between layers. So the application specific layer is publishing a message into the MessageBox and the services layer consumes the message basing on its orchestrations subscriptions. The response path was designed in the same way.
The other thing that should be mentioned is that our team was involved only in the development of the services layer.
We deployed the application in the production environment and after a while we started to receive from time to time the following strange and meaningless error in the event viewer:
Event Type: Error
Event Source: XLANG/s
Event Category: None
Event ID: 10008
Date: 27/10/2007
Time: 04:33:29
User: N/A
Computer: Computer
Description:
Uncaught exception (see the ‘inner exception’ below) has suspended an instance of service ‘ServiceLayer.Service1(92cac9e7-dbe2-d8dd-515b-6805d86d001d)’.
The service instance will remain suspended until administratively resumed or terminated.
If resumed the instance will continue from its last persisted state and may re-throw the same unexpected exception.
InstanceId: 5789b48b-6297-452f-8b41-ff9a6b1090ec
Shape name: Send Service1Msg
ShapeId: 82d935e6-6c3d-4f4e-86e0-1c8ddb679ea3
Exception thrown from: segment 1, progress 59
Inner exception: Exception occurred when persisting state to the database.
Exception type: PersistenceException
Source: Microsoft.XLANGs.BizTalk.Engine
Target Site: Void Commit()
The following is a stack trace that identifies the location where the exception occured
at Microsoft.BizTalk.XLANGs.BTXEngine.BTXXlangStore.Commit()
at Microsoft.XLANGs.Core.Service.Persist(Boolean dehydrate, Context ctx, Boolean idleRequired, Boolean finalPersist, Boolean bypassCommit, Boolean terminate)
at Microsoft.XLANGs.Core.LongRunningTransaction.PendingCommit(Boolean ignore, XMessage msg)
at Microsoft.BizTalk.XLANGs.BTXEngine.BTXPortBase.SendMessage(Int32 iOperation, XLANGMessage msg, Correlation[] initCorrelations, Correlation[] followCorrelations, Context cxt, Segment seg, ActivityFlags flags)
at ServiceLayer.Service1.segment1(StopConditions stopOn)
at Microsoft.XLANGs.Core.SegmentScheduler.RunASegment(Segment s, StopConditions stopCond, Exception& exp)
Additional error information:
A batch item failed persistence Item-ID d3057a06-4e67-45b8-99ce-4c2b4e3c79ac OperationType MAIO_CommitBatch Status -1061151998 ErrorInfo The published message could not be routed because no subscribers were found. .
Exception type: PersistenceItemException
Additional error information:
Failed to publish (send) a message in the batch. This is usually because there is no one expecting to receive this message. The error was The published message could not be routed because no subscribers were found. with status -1061151998.
Exception type: PublishMessageException
For more information, see Help and Support Center at http://go.microsoft.com/fwlink/events.asp.
After some investigation we observed that the issue is manifesting under high load of the services layer. In that scenario the service response time increased considerable so we decided to ask the guys that implemented the specific application layer how they deal with such a scenario. We found out that they had implemented a timeout mechanism that signal the front-end application about the timeout and terminate the orchestration.
It was clear for us that the problem has something to do with the Direct Binding and with the fact that the consumer orchestration is closed before receiving its response. The service orchestration publishes a message that doesn’t have any subscriber because the consumer orchestration is terminated meanwhile.
In order to reproduce this behavior we created a test application with two orchestrations: a consumer orchestration and a service orchestration. The consumer application publishes a message and waits for the response for a given time… if the time expires it will terminate. The service orchestration has some delay activity that will let enough time to the consumer to terminate before sending the response. The same error is received with the test application.
In conclusion, you should pay attention and not terminate the consumer orchestrations that are involved into Direct Binding communication pattern before receiving the response, otherwise the administration work will become interesting or the application will remain in an inconsistent state.


Hi there, I agree with your blog and I will be back to check it more in the future so please keep up your good quality work. I love your content & the way that you write. It looks like you’ve been doing this for a while now, how long have you been blogging for? You make it look easy
I enjoyed viewing your blog and I will be back to check it more in the future so please keep up your good quality work. I love the colors that you chose, you are quite talented!
I couldn’t resist commenting.
Hey I was just looking thru your website on my Blackberry and I was wondering how well it will work on the new ipad coming out . Fleeting thought…. Anyway thanks!
Great points…I would note that as someone who really doesn’t write on blogs much (in fact, this may be my first post), I don’t think the term “lurker” is very becoming to a non-posting reader. It’s not your fault really , but perhaps the blogosphere could come up with a better, non-creepy name for the 90% of us that enjoy reading the content .
I really don’t believe Chelsea won!! I hope Wayne Rooney is not injured soon so that Man Utd can start winning once more!
Hiya, I was reading an additional issue about this on another blog. Interesting. Your perspective on it’s diametrically contradicted from what I read earlier. I’m still pondering of the opposite items of view, but I’m leaning to a excellent extent toward yours. And irrespective, that is certainly what’s so perfect about current democracy as well as the industry of ideas online.
I believe you might like what I came across on this internet site today.
hey, I’m unable to subscribe for the RSS feed. Can you assist or do you know why? thanks for the info.
This is a good post, please continue the good work with this blog!
This is a great post, please continue the fine work with this blog!
Hey mate, greetz from New York!
Heya, extremely high-quality online site. Kudos for making the effort to publish those fascinating posts
How-do-you-do, just needed you to know I have added your site to my Google bookmarks because of your extraordinary blog layout. But seriously, I think your site has one of the freshest theme I’ve came across. It really helps make reading your blog a lot easier.
I feel you are too good to write Genius!Thanks for posting, maybe we can see more on this.
Well I found this on Digg, and I like it so I dugg it!
I feel you are too good to write Genius!Thanks for posting, maybe we can see more on this.
Good! Thank you! I always wanted to write in my site something like that. Can I take part of your post to my blog?
Thank you! I really appreciate your article, in fact I think you deserve a thumbs up.
Amusing post,I would quite like to subscribe to your blog
I will use your advice from now on. Jaap
Hi! If you need help with wix support, don’t hesitate to enter this live help page : wix.com live support
Various people in the world get the credit loans from various banks, just because it’s fast and easy.
I just wanted to comment your blog and say that I really enjoyed reading your blog post here. It was very informative and I also digg the way you write! Keep it up and I’ll be back to read more soon mate
Hi, maybe i’m being a little off subject here, but I was browsing your website and it looks inviting. I’m writing a weblog and trying to create it appear neat, but everytime I touch it I mess some thing up. Did you style the weblog yourself? Could somebody with minor experience do it, and add updates without messing it up? Anyways, very good info on right here, really solid.
You certainly deserve a round of applause for your post and more specifically, your blog in general. Very high quality material.
I’ve been visiting your blog for a while now and I always find a gem in your new posts. Thanks for sharing.
Which golf clubs will be the best for beginner ?
I like the first point you made there, but I am not sure I could reasonably apply that in a productive way.
Super site, and nice text.
You certainly have some agreeable opinions and views. Your blog provides a fresh look at the subject.
Thanks For This Post, was added to my bookmarks.
Have you ever considered adding more videos to your blog posts to keep the readers more entertained? I mean I just read through the entire article of yours and it was quite good but since I’m more of a visual learner,I found that to be more helpful well let me know how it turns out! I love what you guys are always up too. Such clever work and reporting! Keep up the great works guys I’ve added you guys to my blogroll. This is a great article thanks for sharing this informative information.. I will visit your blog regularly for some latest post.
You certainly have some agreeable opinions and views. Your blog provides a fresh look at the subject.
Awesome Post. I add this Post to my bookmarks.
Not often you can find cool theme for wpress. There are very nice themes, but very limited to set up. I have installed recent versions of MASUGID, My Office, Secret Garden 2, Rockwell, also I have tried also BlueSense – simple, but made for adsense. Very rarely I can find something cool but rich in options.
I’ve been searching for and seek for info and info regarding this for pretty some time now. Many because of the helpful insight.
You certainly deserve a round of applause for your post and more specifically, your blog in general. Very high quality material.
Which golf clubs will be the best for beginner ?
I made a little video about this, would you consider taking a peak at it and maybe leaving your opinion about it? I put the video url in the “website” field so hopefully you can get to it. thanks much
I must say, I thought this was a pretty interesting read when it comes to this topic. Liked the material. . . . .
You certainly deserve a round of applause for your post and more specifically, your blog in general. Very high quality material.
Would you mind taking a minute of your time to help us out with a quick eval? Compensation is provided to the quickest who can help us. We left the link in the proper field, thankyou
There are certainly a lot of details like that to take into consideration. That?s a great point to bring up. I offer the thoughts above as general inspiration but clearly there are questions like the one you bring up where the most important thing will be
What a good blog you have here. Please update it more often. This topics is my interest. Thank you. . .
I wanted to thank you for this great read!! I definitely enjoying every little bit of it.I have you bookmarked to check out new stuff you post.
Pretty good post. I just stumbled upon your blog and wanted to say that I have really enjoyed reading your blog posts. Any way I’ll be subscribing to your feed and I hope you post again soon.
Advantageously, the post is in reality the freshest topic on curing acne naturally. I concur with your conclusions and will thirstily look forward to your upcoming updates. Just saying thanks will not just be enough, for the phenomenal clarity in your writing. I will right away grab your rss feed to stay abreast of any updates.
google talk iphone
google country maps