Strange 401 (Unauthorized) when calling a WCF Service
Posted
by mipsen
on Geeks with Blogs
See other posts from Geeks with Blogs
or by mipsen
Published on Thu, 30 Dec 2010 06:41:54 GMT
Indexed on
2010/12/30
6:55 UTC
Read the original article
Hit count: 295
A WCF Service we call from BizTalk using WCF BasicHTTP usually works fine but all of a sudden it started returning 401 errors for some calls while others continued working as expected so it could not have been a "real" 401. The difference was the size of the message. One parameter of the service is a rather complex object. In the cases we got a 401 it got quite big (containing a lot of customer-data), say 5 MB. So we turned on tracking. The messages we traced out where about 20MB. Not too big for WCF one should suppose...
A bit of research led us to increasing maxItemsInObjectGraph in the behaviours but that did not help.
The service we call is in the same network as we are and is a WCF service. So we tried changing from BasicHTTP to net.tcp and Bingo! Ok, we had to use CustomBinding in BizTalk to set all the Quotas, etc. but it worked in the end.
© Geeks with Blogs or respective owner