none
Wcf external use . svc service RRS feed

  • Question

  • Hi Everyone 

    I have a problem. When localhost use wcf service no problem but external link add refence exm:inorthwind.com/Service1.svc/getAllCustomers  this link dont use my project  its give me error dont listen endpoint etc. , which I will follow way .. pls help me .. thx..


    Thursday, January 29, 2015 3:51 PM

Answers

  • okey.  you mean ,is the end point for other servers to define the rope?

    I don't know what you are talking about. I gave you the answer, and it was explained to you what was happening. Let's revisit here.

    http://computer.howstuffworks.com/internet/basics/question549.htm

    http://whatismyipaddress.com/localhost

    http://www.urbandictionary.com/define.php?term=127.0.0.1

    http://www.webopedia.com/TERM/L/loopback_address.html

    The WCF works locally on your machine becuase the loopback IP is being used on the definition of the endpoint that points to the WCF service that is hosted on a computer as defined in the app.config or Web.config that the WCF client is using. The traffic never leaves the local computer (the loopback)  loops the traffic back to the local computer, since the WCF client and service are running locally on the same machine.

    Computer A has the WCF client software running. Computer B has the WCF service software running, and both computers are on a network. What piece of information in the client-side config file (the endpoint) that defines the location of the machine that is hosting the WCF service must be changed in order so the client machine with the WCF client can find the machine that is hosting the WCF service. 

    What happens if you went to the client-side WCF client config file and changed 'localchost' to '127.0.0.1' on the endpoint? What is the end result of you making that change? What do you expect to happen?

    How do computers communicate with each other over a network based on the first link in this post? What is the one piece of information that must be given on the endpoint so that the WCF client machine and WCF service machine can communicate with each other?

    It doesn't take Albert Einstein to figure it out.

    Friday, January 30, 2015 3:05 PM

All replies

  • The client mecghine hoting the WCF client must know the IP of the computer that is hosting the WCF service, which would be given in the WCF client confilg file.

    You see the word 'localhost' in the config file  or anywhere for that matter, and it means this.

    http://en.wikipedia.org/wiki/Localhost

     'localhost' = 127.0.0.1 and you can put '127.0.0.1' there instead of 'localhost' and it means the same thing.

    So, when WCF service is deployed to a computer on a local area network  LAN, the then WCF client must give the IP of the computer that is hosting the WCF service on the LAN, which is done in the WCF client's config file.

    If the computer is out there on the Internet (WAN)  wide area network, then the IP to the Internet site must be given in the WCF client's config file , and behind the scenes, the traffic is routed to the machine at the site that is hosting the WCF service. I am not going into detail on how this works.

    • Marked as answer by ilhan88 Friday, January 30, 2015 8:42 AM
    • Unmarked as answer by ilhan88 Friday, January 30, 2015 8:42 AM
    Thursday, January 29, 2015 4:37 PM
  • okey.  you mean ,is the end point for other servers to define the rope? 
    Friday, January 30, 2015 8:48 AM
  • okey.  you mean ,is the end point for other servers to define the rope?

    I don't know what you are talking about. I gave you the answer, and it was explained to you what was happening. Let's revisit here.

    http://computer.howstuffworks.com/internet/basics/question549.htm

    http://whatismyipaddress.com/localhost

    http://www.urbandictionary.com/define.php?term=127.0.0.1

    http://www.webopedia.com/TERM/L/loopback_address.html

    The WCF works locally on your machine becuase the loopback IP is being used on the definition of the endpoint that points to the WCF service that is hosted on a computer as defined in the app.config or Web.config that the WCF client is using. The traffic never leaves the local computer (the loopback)  loops the traffic back to the local computer, since the WCF client and service are running locally on the same machine.

    Computer A has the WCF client software running. Computer B has the WCF service software running, and both computers are on a network. What piece of information in the client-side config file (the endpoint) that defines the location of the machine that is hosting the WCF service must be changed in order so the client machine with the WCF client can find the machine that is hosting the WCF service. 

    What happens if you went to the client-side WCF client config file and changed 'localchost' to '127.0.0.1' on the endpoint? What is the end result of you making that change? What do you expect to happen?

    How do computers communicate with each other over a network based on the first link in this post? What is the one piece of information that must be given on the endpoint so that the WCF client machine and WCF service machine can communicate with each other?

    It doesn't take Albert Einstein to figure it out.

    Friday, January 30, 2015 3:05 PM