Linq with WCF

by OfirYaron 8/3/2009 7:51:00 AM

"An error occurred while receiving the HTTP response to
http://xxx/. 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."

Got this message while trying to communicate to a WCF service I’ve built,

My initial assumption was that I’m not using the suitable security binders at both sides (server and client) .

First thing I tried was striping down the authentication configuration to “none” – the same exception was still thrown.

Secondly I tried to remove the service functionality to most basic by returning null, It works, I’ve returned the functionality but kept returning null and guess what - still worked.

At this point it was clear that the is some problem with the object that I try to return, I assumed that my Linq to Sql objects were not Serialized, indeed that was the cause, if you’re having this exception and use Linq to Sql object as a returned object – Its probably it.

Here is a very helpful “how to” on the subject: http://www.west-wind.com/Weblog/posts/147218.aspx 

(All that need to be done is changing the DataContext Serialization Mode to Unidirectional)

Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Tags: ,

WCF

Related posts

Comments

9/8/2009 9:35:27 PM

i feel very lucky can find this page..
finally i find something that i want to know..
thank you for this usefull informations..

Stop Dreaming Start Action us

11/19/2009 2:14:54 PM

i really appreciate this your good article
from there i get something that i want to know
thanks for this usefull informations

electric diagram us

Comments are closed

Powered by BlogEngine.NET 1.3.0.0
Theme by Mads Kristensen

About the author

Name of author Author name
Something about me and what I do.

E-mail me Send mail

Calendar

<<  July 2010  >>
MoTuWeThFrSaSu
2829301234
567891011
12131415161718
19202122232425
2627282930311
2345678

View posts in large calendar

Recent posts

Recent comments

Authors

Disclaimer

The opinions expressed herein are my own personal opinions and do not represent my employer's view in anyway.

© Copyright 2010

Sign in