开发者

how much of the app.config of a WCF Service Library has to be copied over to app.config of a Console Host?

How much o开发者_如何学Gof the app.config from the WCF Service Library has to be duplicated in the Console Host's app.config?


Basically: everything.

The app.config for the WCF service class library will not be read by .NET.

You need to have all the settings (more specifically: everything in <system.serviceModel> section) into your host application's app.config file.

@Broyian: WCF configuration is a notoriously difficult and often not very well understood topic. I have two video show episodes that I really like that helped me understand configuration a lot better - check them out!

  • DotNet Rocks TV Show #122: Miguel Castro on Extreme WCF
  • DotNet Rocks TV Show #135: Keith Elder Demystifies WCF

@Broiyan: you might want to check out this blog post here about improvement in WCF 4.0 making it less of a "beast":

  • Why ASMX web services are not an excuse anymore with WCF 4.0


I may not understand the question, but if you are trying to get rid of the app.config in a WCF client application (ie to put everything inside of a DLL), see here

C# WCF: Having a single app.config in a shared library that provides access to the Service

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜