Best way to manage multiple Service References in .NET

后端 未结 3 770
南笙
南笙 2021-02-06 18:45

I have a C# ASP.NET project with 15 WCF/ASMX Service References. Each service is deployed to three different servers; test, staging and live

3条回答
  •  温柔的废话
    2021-02-06 19:00

    One technique is to get the endpoint and replace the URL in code (e.g., you can do it from a database), with something like this:

    endpoint.Endpoint.Address = new System.ServiceModel.EndpointAddress(remoteUrl);
    

提交回复
热议问题