Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Problems with wsHttpBinding
Message
From
05/04/2012 11:20:37
 
 
General information
Forum:
ASP.NET
Category:
Windows Communication Foundation (WCF)
Environment versions
Environment:
C# 4.0
Miscellaneous
Thread ID:
01540381
Message ID:
01540423
Views:
38
Thanks Viv ... you got my brain going in a different direction and I've fixed the problem (after staring at this for days)!!

When I tried to use Fiddler, it worked fine!! As soon as I stopped Fiddler, it crashed and burned again. I tried using the IP instead of the computer name and then it worked. Fiddler must have done something when I used the computer name and maybe that's why it worked then.

Anyway problem solved ... use IP instead of computer name!!

Thanks!!

~~Bonnie



>Hi,
>Do you mean that in each case the server and client are running on the same box ?
>If that is the case I'd be more inclined to suspect the service address rather then the different OSes.
>What is 'myMachine' ?
>Did you try using Fiddler?
>
>>OK, this is a really weird one. Well, seems weird to me anyway. I've got a WCF service that is, for testing, hosted in a Console app (normally it's hosted in a Windows Service). It doesn't do anything fancy. No large amount of data is returned, hardly any actually ... a short string for test purposes.
>>
>>In my config, if my endpoints are net.tcp, everything works fine on both my XP laptop and a Windows 2008 R2 server. If I change the config to make the endpoints http (and use wsHttpBinding), it doesn't work on XP but it does work fine in 2008. The error is the typical non-helpful error (and using diagnostics and service traces doesn't give me any additional info ... I've already tried that):
>>
>>An error occurred while receiving the HTTP response to http://mymachine:52499/Geneva.MyService. This could be due to the service endpoint binding not using the HTTP protocol. This could also be due to an HTTP request context being aborted by the server (possibly due to the service shutting down). See server logs for more details.
>>The underlying connection was closed: An unexpected error occurred on a receive.

>>
>>My hypothesis is that there is additional stuff I need to put into the bindingConfiguration that doesn't need to be there for 2008, but definitely needs to be there for XP. Why that should matter, I have no clue, but here are the relevants bits from the configs:
>>
>>
>><services>
>>  <service name="Geneva.MyService">
>>    <endpoint address="http://mymachine:52499/Geneva.MyService"
>>        binding="wsHttpBinding" bindingConfiguration="wsHttpConfig"
>>        contract="Geneva.IMyService" />
>>  </service>
>></services>
>><bindings>
>>  <wsHttpBinding>
>>    <binding name="wsHttpConfig" openTimeout="00:00:30" sendTimeout="00:00:30" 
>>        maxBufferPoolSize="4000000" maxReceivedMessageSize="4000000">
>>      <readerQuotas maxDepth="4000000" maxStringContentLength="4000000"
>>          maxArrayLength="4000000" maxBytesPerRead="4000000" maxNameTableCharCount="4000000" />
>>    </binding>
>>  </wsHttpBinding>
>></bindings>
>>
>>
>>And for the client (the bindings section is the same as above):
>>
>>
>><client>
>>  <endpoint name="GatewayEndpoint"
>>          address="http://mymachine:52499/Geneva.MyService"
>>          binding="wsHttpBinding" bindingConfiguration="wsHttpConfig"
>>          contract="Geneva.IMyService"/>
>></client>
>>
>>
>>Anyone see what I might be missing in the wsHttpConfig? (Incidentally, when I used netTcpBinding, my netTcpConfig was exactly the same as the wsHttpConfig.)
>>
>>~~Bonnie
Bonnie Berent DeWitt
NET/C# MVP since 2003

http://geek-goddess-bonnie.blogspot.com
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform