简体   繁体   中英

WCF self hosting and IIS

Does WCF self hosting, still uses IIS or some Virtual Server based on IIS.

Eg: After coding a very basic WCF host, it s possible to invoke an endpoint such as
http://localhost:9090/foo.svc

For example: invoking a WCF host via TCP, does that use IIS internally?

I m trying to avoid IIS due to another app im using, which doenst work with IIS Threads. That s why asking. so id like to manage my own AppDomain and threadpool rather than IIS.

Any recommendation?

Can i seperate hosting of WCF from IIS?

When you self-host, you are using not a shred of IIS at all. You don't need IIS on that machine - nothing.

WCF self-hosting will require the http.sys driver for its http-based communication - but that's all there is. There is absolutely no trace of IIS needed - none, zip, nada.

Self-hosting WCF also allows you to pick your own service addresses and use whatever suits your needs - there's no virtual directory and no *.svc file to be dealt with.

It depends on the bindings. if you do a BasicHttpBinding, then all the communication will be over HTTP.

As for hosting WCF, there is the test server that comes with Visual Studio that you can use (it runs as a service. It's called WcfSvcHost.exe ), but I wouldn't recommend it for production. If you are just testing, then you could just launch the WCF in the Visual Studio debugger and use its address all you want (it will be http://localhost:1234/foo.svc in that case)

If you are looking for a production hosting, you can use WCF as a SOAP endpoint , and here there is a pretty good article over at The Code Project that talks about creating a service for self hosting

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM