WCF EndPoint Application

I quote from MSDN:

application endpoint
The endpoint opened by the application and corresponding to the service contract implemented by the application.

Can someone explain this definition to me? Is the application endpoint the same as the service link created by Visual Studio?

+4
source share
2 answers

All WCF Communications Service Runs Through Endpoints . It gives customers access to the features provided by WCF.

Each endpoint has three properties:

  • Address (where)
  • Binding (how)
  • Contract (what)

Endpoints can also have a set of rules that define local implementation details. endpoints exist for both clients and services: WCF services can provide multiple endpoints, and a client can communicate with services with multiple endpoints.

Can someone explain this definition to me? Is the endpoint application the same as the link to the service created by Visual Studio?

When you add a service link, Visual Studio will add a new client endpoint to your application (check the updated configuration file). However, Visual Studio will attempt to download metadata first to list all available endpoints for the address.

+2
source

The main explanation:
The endpoint of the application is the address to which your customers will connect to receive an instance of the service that implements the specified “service contract”.

Further explanation:
WCF works through interfaces, not classes. Each of these interfaces is known as a “Service Contract”. One class could implement more than one interface, so two service contracts could be organized by one class. You did not ask about it, but I thought that I should get it too.

To answer your question, one interface can be connected in several ways. Each of these methods is called Application Endpoints . Here is an example: you might want people to be able to connect using HTTP for external connections or named pipes for requests generated on the same computer for better performance. By setting two endpoints up for one "Service Contract", which allows you to have such flexibility.

0
source

Source: https://habr.com/ru/post/1498129/


All Articles