Domain Name and IP address problems in the address after the release of WCF

Source: Internet
Author: User

Network reference: http://topic.csdn.net/u/20080423/15/4bbf1e34-7419-44e2-96d1-dfa29300d2be.html

Recently, I have been learning about WCF and have been confused about address issues. I use IIS as the host. Assume that the server address is 10.8.8.8, the server host name is mycoputer, And the. SVC file address is http: // localhost/WCF/service. SVC.
Access http: // localhost/WCF/service. SVC on the server. The help page appears, prompting me to use
Svcutil.exe http: // mycoputer/WCF/service. SVC? WSDL
Reference Service, which is no problem on the server. It can identify its own domain name http: // mycoputer, but it cannot resolve the domain name http: // mycoputer on other machines, therefore, http: // mycoputer/WCF/service cannot be referenced. SVC? WSDL. Later, I set the httpgeturl attribute and forcibly set the httpget address of the metadata to http: // 10.8.8.8/WCF/service. SVC/meta, you can use http: // 10.8.8.8/WCF/service on other machines. SVC/meta? WSDL reference service.
However, the base address in the operation is still http: // mycoputer/WCF/service. SVC, an exception occurs when other machines call the service. It does not work if I use the

 

 

After testing, I found that the host name bound to the website can be filled in with an IP address in IIS, which can avoid the problem of mismatch between host domain name resolution and IP address.

 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.