Should I use localhost in the endpoint address of a WCF service? -



Should I use localhost in the endpoint address of a WCF service? -

if host publicly available wcf web service in iis, how should configure endpoint address? think can utilize either:

<endpoint address="http://localhost/myservice" ... />

or

<endpoint address="http://example.com/myservice" ... />

in both cases, client on machine must utilize sec alternative client binding.

if utilize visual studio create client, both server bindings seem work fine. however, think had problem using new-webserviceproxy in powershell first option.

does matter 1 utilize on server?

msdn: specifying endpoint address:

you must utilize relative endpoint addresses iis-hosted service endpoints. supplying fully-qualified endpoint address can lead errors in deployment of service. more information, see deploying net info services-hosted wcf service.

from link:

when hosted in iis, endpoint addresses considered relative address of .svc file represents service. example, if base of operations address of wcf service http://localhost/application1/myservice.svc next endpoint configuration.

<endpoint address="anotherendpoint" .../>

this provides endpoint can reached @ http://localhost/application1/myservice.svc/anotherendpoint

web-services wcf iis

Comments

Popular posts from this blog

xslt - DocBook 5 to PDF transform failing with error: "fo:flow" is missing child elements. Required content model: marker* -

mediawiki - How do I insert tables inside infoboxes on Wikia pages? -

Local Service User Logged into Windows -