0
votes

I have a WCF web-service with four different clients , one of our clients wants more functionality , so we are adding , new OperationContract , which will use new DataContracts and some existing one

  • Existing Operation Contracts or DataContracts are not being modified
  • We will just be adding new OperationContracts and few new DataContracts

    1. Would all of our clients have to update their service reference ? ( or clients who don't want the additional functionality of new methods, can go on using the service as they were)

    2. if all of the clients would have to update their service reference , is there a way around it ? ( I want that only the clients who want to use the new operationContract , should update the service reference )

We have netTcp and basichttp bindings

2
i did and there was this another question on stackoverflow expression concern about nettcp binding in such a scenario ..anyway my question is answered now , thanks.Sandarbh Singh

2 Answers

0
votes

WCF is very flexible when in comes to versioning as shown in this good MSDN article. If you change a service contract exposed automatically through a MEX endpoint, then all clients will have access to the new changes.

If you want to tightly control the contract exposed by a service then you could turn off the MEX endpoint and distribute the edited WSDL (and appropriate XSDs if not using singlefile) files to specific clients. Do not consider this a security measure since all you're doing is "obscuring" the fact that the service supports more operations that you are revealing.

If you do need to secure the different contracts then you will need to create separate services to expose the appropriate contracts to authorized clients.

0
votes

Existing clients do not need to change. Under the hood the contract between clients and the server are soap messages according to the schema of specific operations. Since these operations have not changed the soap is the same so clients will work.