Skip to content

Commit

Permalink
service via discovery called
Browse files Browse the repository at this point in the history
  • Loading branch information
shishkin committed May 28, 2010
1 parent 9c68c14 commit b0295be
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
8 changes: 8 additions & 0 deletions SimpleClient/Program.cs
Expand Up @@ -29,6 +29,14 @@ static void Main(string[] args)
{
Console.WriteLine("{0}", endpoint.Address);
}

var channelFactory =
new ChannelFactory<EchoService>(
new BasicHttpBinding(),
service.Endpoints.FirstOrDefault().Address);
var response = channelFactory.CreateChannel().Echo("hello!");
Console.WriteLine(response);

}
}
}
4 changes: 0 additions & 4 deletions SimpleService/Program.cs
Expand Up @@ -25,10 +25,6 @@ static void Main(string[] args)
typeof(EchoService),
new Uri("http://localhost:8081/Echo")))
{
host.AddServiceEndpoint(
typeof(EchoService),
new WSHttpBinding(),
"ws");
host.AddServiceEndpoint(new UdpDiscoveryEndpoint());
host.AddDefaultEndpoints();
host.Open();
Expand Down

0 comments on commit b0295be

Please sign in to comment.