1

Can you have multiple BizTalk receive host instances accessing a single SB topic/subscription?

We have a BizTalk 2013 R2 cluster with two machines, and sometimes were finding access to a SB topic/subscription stalls ...

And we have loads of event log warning about locks ...

"Microsoft.ServiceBus.Messaging.MessageLockLostException: The lock supplied is invalid. Either the lock expired, or the message has already been removed from the queue

The fix seems to be stopping one of the two receive hosts, stop/start the other receive host, and it happily processes through the SB messages

SteveC
  • 13,636
  • 21
  • 86
  • 155
  • 2
    Hi Steve. It does sound like you need to configure the host only to run on a single instance like some of the other adapters like FTP, SFTP, MSMQ as mentioned in https://docs.microsoft.com/en-us/biztalk/core/considerations-for-running-adapter-handlers-within-a-clustered-host1 I would also add SQL Polling to that list. – Dijkgraaf Jun 07 '18 at 21:45
  • @Dijkgraaf Yeah, I wondered if the SB-Messaging adapter had to be single host, like FTP, but I assumed it'd be using Peek-Lock, so only one of the hosts would get a lock. But I can't find anything on the Microsoft doc's :-( – SteveC Jun 08 '18 at 07:39
  • 2
    I couldn't find any documentation or even a blog post from anyone about it either. Maybe you should try it and see if that makes the issues stop, in which case you can write that blog ;-) – Dijkgraaf Jun 08 '18 at 20:49

1 Answers1

1

Well, there is surprisingly little guidance on this topic so I'm going give an answer based on experience and expert opinion. ;)

You should treat the Service Bus Messaging Adapter in the same way we treat receive operations for other queueing system such as MSMQ or WMQ.

The Receive Adapter should be run in a clustered Host Instance to ensure only one is active at a time.

Johns-305
  • 10,704
  • 10
  • 21