WCF contract changes that affect clients

前端 未结 5 1407
南笙
南笙 2021-02-01 10:31

I was curious if someone could outline which types of WCF contract (interface) changes on the server side would break a client trying to send in a message, and why. I believe W

5条回答
  •  太阳男子
    2021-02-01 11:02

    "Add/remove parameters from an OperationContract" in WCF is not always something that can break your client, but you have to know what you do. In particular, adding new parameters to an operation contract will cause legacy clients not to pass them, and on the service side they will be set with their default values. Moreover, removing parameters from an operation contract, will be silent from the client point of view, and they will be simply ignored on the service side. Of course, changing parameter's name/type will cause the client to break.

提交回复
热议问题