WCF Essentials—Endpoints
| CSharp-Online.NET:Articles |
| .NET Articles |
| © 2007 O'Reilly Media |
Endpoints
Every service is associated with an address that defines where the service is, a binding that defines how to communicate with the service, and a contract that defines what the service does. This triumvirate governing the service is easy to remember as the ABC of the service. WCF formalizes this relationship in the form of an endpoint. The endpoint is the fusion of the address, contract, and binding (see Figure 1-5).
Every endpoint must have all three elements, and the host exposes the endpoint.
Logically, the endpoint is the service’s interface, and is analogous to a CLR or
COM interface. Note in Figure 1-5 the use of the traditional "lollipop" to denote an
endpoint.
Every service must expose at least one business endpoint and each endpoint has exactly one contract. All endpoints on a service have unique addresses, and a single service can expose multiple endpoints. These endpoints can use the same or different bindings and can expose the same or different contracts. There is absolutely no relationship between the various endpoints a service provides.
It is important to point out that nothing in the service code pertains to its endpoints and they are always external to the service code. You can configure endpoints either administratively using a config file or programmatically.
|


