wcf

Are there any guarantees about when IIS might recycle while processing a 1-way WCF operation?

Background This question is in two parts. I have a one-way WCF operation hosted in IIS 6. The following is my understanding of how this works: _1. IIS receives a request. _2. IIS sends an HTTP 202 response (thanks, I'll process this later). _3. IIS calls my one-way WCF operation. Now control passes to my WCF operation w...

HTTP POST XML to REST Singleton Service throws NotSupportedException

I have the following REST Host in a silverlight application. I'm getting a NotSupportedException on the EndGetResponse() call of the Save Method. In this sample I'm using the default config for a REST Singleton Service from the WCF REST Starter Kit, with the exception of some changes to the OnAddItem method to accept updates via a POST...

Where is Juval Lowy's ServiceModelEx library for WCF?

WCF is Microsoft's replacement for .Net Remoting and Web services. It's critical to understand if you are a .NET component developer. The best reference for WCF appears to be (by word of mouth, blogs and Amazon) Juval Lowy's "Programming WCF Services," published by O'Reilly. This book is advertised in several places around the net a...

Silverlight & WCF: Max message size

Hi there, When I pass a list of objects out of my silverlight app using WCF everything works fine until the List grows too big. It seems that when I exceed 80 items I get the error: The remote server returned an unexpected response: (404) Not Found I'm presuming that it's because the List has grown too big as when the List had 70 items...

SQL Server Database File and WCF

I have a WCF Service that exposes a method GetCustomers(). The internals of the method uses a Data Layer along with a Business Layer to return a List of Customers. Currently I am using an SQL Server Database file saved on the server. Everything works fine on my local network but I want to move this to the web. I thought the best method ...

Best Practice for WCF Service Proxy lifetime?

When working with WCF services, is it better to create a new instance of the service every time you use it? Or is it better to create one and re-use it? Why is either approach better? Is it the same for asynchronous proxies? ...

Accessing the Response object from my WCF service

Hi all, In my WCF service class which is in the same project as my WebSite I inherit from System.Web.UI.Page so that I have access to the Page.Response object but when I use it I get the error: "Response is not available in this context." I want to save to a file the results passes in to my WCF service like so: public void ...

IIS7 / WPAS: Multiple WCF services in same AppDomain?

If host my WCF services in IIS7 or WPAS, is it possible to load up two or more services into the same AppDomain so that they can share static variables? ...

Run WCF ServiceHost with multiple contracts

Running a ServiceHost with a single contract is working fine like this: servicehost = new ServiceHost(typeof(MyService1)); servicehost.AddServiceEndpoint(typeof(IMyService1), new NetTcpBinding(), "net.tcp://127.0.0.1:800/MyApp/MyService1"); servicehost.Open(); Now I'd like to add a second (3rd, 4th, ...) contract. My first guess would...

WCF REST vs. ADO.NET Data Services

Hi there, Could someone compare and contrast on WCF Rest services vs. ADO.NET Data Services? What is the difference and when to use which? Thanks, Ray. Edit: thanks to the first answer, just to give a bit background on what I'm looking to do: I have a web app I plan to put in the cloud (someday), the DAL is built with ADO.NET Entity...

How can I configure WCF to use x509 certificates over the internet?

I need to use an x509 certificate to get secure message level authentication from a rich client via the internet to a secure WCF Web Service. Specifically, I am looking for a working step-by-step guide to setup, configuration, coding, and deployment, including creating a 'dev' certificate, installing it, and obtaining a 'real' certifica...

How do I tell WCF to skip verification of the certificate?

Trying to make a web service call to an HTTPS endpoint in my Silverlight application results in this error: "Could not find a base address that matches scheme https for the endpoint with binding WSHttpBinding. Registered base address schemes are [http]" The same problem as was posted here: http://social.msdn.microsoft.com/Forums/en-US/...

How to Create a Listener for WCF ServiceHost events when service is hosted under IIS?

I have a WCF service which will be hosted under IIS. Now I have some resources(Connections) that I create within service constructor. I need to free up those resources when IIS which is hosting the service shuts down or resets. These are not the resources that I will be clearing out every time client disconnects but they are application ...

Resolving Configuration Error in WCF AddressFilter Mismatch

I am getting the following error and could use some help resolving it. Anyone have any ideas? The message with To 'http://localhost:60078/BidService.svc/Query' cannot be processed at the receiver, due to an AddressFilter mismatch at the EndpointDispatcher. Check that the sender and receiver's EndpointAddresses agree. The client config...

How can I improve this perWcfOperation Windsor lifestyle?

I have implemented a custom lifestyle for Windsor that will allow me to scope components to the current WCF operation. The biggest problem is that the call context initializer is executed after the service has been constructed which means that it cannot have dependencies on components with a perWcfLifestyle because the context for the pe...

How to: Responsive available Wcf duplex communication

I'm working on an application that uses WCF to communicate between server and clients Server has changing number of services, along with one master service that clients can query for information about other services, and then subscribe to those they want using information from master service. Master service sends notifications to subscr...

How can I make Named Pipe binding reconnect automatically in WCF

I'm writing a service that will only get calls from the local host. Performance is important so I thought I'd try the NetNamedPipeBinding instead of NetTcpBinding and see If I could see any noticeable performance gains. If a client, after having performed one or more requests to the server, is idle for a longer period of time the next r...

wcf service to service communication & data contract

hi all! i have recently been involved in developing a WCF service which acts as a kind of multicast relay (i.e. accepts some incoming data, does some processing and then sends it off to multiple other external services). this service (which i will refer to as "my service") is fed data by a second internal service. this data is going to...

WCF Service hosted in IIS6 gets 404 in Production

I have built a simple WCF Service and deployed it to IIS6, and I'm noticing that it works in my Dev and Staging environments, but not Production. Every time I try to hit the service metadata link, I get a 404 page. I've checked IIS config everywhere I can think of and they're identical, so the only difference I can think of is that the...

"The creator of this fault did not specify a Reason" Exception

I have the following code in WCF service to throw a custom fault based on certain situations. I am getting a "The creator of this fault did not specify a Reason" exception. What am I doing wrong? //source code if(!DidNotPass) { InvalidRoutingCodeFault fault = new InvalidRoutingCodeFault("Invalid Routing Code - No Approval Started"...