简体   繁体   中英

Testing for EndPoint compatibility with IIS hosted WCF service

I am trying to deploy a WCF service to IIS. I would like to offer both HTTP and HTTPS endpoints, but Im not guaranteed that the IIS servers will have HTTPS available. If its not, then my service will fail start.

Is it it possible to test if an endpoint is viable before adding it to the service? Right now i am limited to using .NET 3.5(sp1)

If your site exposes some page with known address you can try to access it with HttpWebRequest over HTTPS but I don't think it is a good idea. Wrap your deployment into installation package and offer administrator to choose if HTTPS endpoint should be used or not. Your installation package will modify service configuration based on administrator's choice.

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