c# - relationship between configuration in app.config or web.config and code in WCF -


how service host in wcf interact configuration web.config or app.config. when create service host specify url in service host constructor , class of service.

but in app.config or web.config have list of endpoints, each it's own specific url. how wcf handle situation? endpoint take app.config or web.config?

the address of endpoint relative base address of service host. example, if had these endpoints:

<service name="myservice">     <endpoint address="" binding="ws2007httpbinding" contract="imyservice" />     <endpoint address="mex" binding="mexhttpbinding" contract="imetadataexchange" /> </service> 

and service host url of http://localhost:7777, exposing service on http://localhost:7777, , metadata on http://localhost:7777/mex.


Comments

Popular posts from this blog

monitor web browser programmatically in Android? -

Shrink a YouTube video to responsive width -

wpf - PdfWriter.GetInstance throws System.NullReferenceException -