Loading WCF config (for server + client) from custom source (not standard XML)

前端 未结 1 1670
孤城傲影
孤城傲影 2021-01-06 03:18

I\'ve been trying to find a way to load my WCF service configuration (that huge BLOB of XML config data) from an alternate source - not the standard web.config / app.config.

1条回答
  •  攒了一身酷
    2021-01-06 03:52

    You can do this, it's a little bit of work though.

    On the service side, You'll have to create your own custom ServiceHost and override the ApplyConfiguration method.

    Check out this blog post

    On the client side, you do something similar, but provide a custom ChannelFactory and override the ApplyConfiguration method there.

    0 讨论(0)
提交回复
热议问题