Ci-dessous, les différences entre deux révisions de la page.
Les deux révisions précédentes Révision précédente Prochaine révision | Révision précédente | ||
cours:app_rep_orientees_service_2016_2017:lab_abc [2019/04/24 07:16] tigli [Creation of various endpoints in configuration] |
cours:app_rep_orientees_service_2016_2017:lab_abc [2019/04/24 07:33] (Version actuelle) tigli [Introduction] |
||
---|---|---|---|
Ligne 1: | Ligne 1: | ||
- | ==== Introduction ==== | + | ==== Few reminders about WCF ABC Model ==== |
The ABC of Windows Communication Foundation | The ABC of Windows Communication Foundation | ||
Ligne 21: | Ligne 21: | ||
* You choose or define a service binding that selects a transport along with quality of service, security and other options | * You choose or define a service binding that selects a transport along with quality of service, security and other options | ||
* You deploy an endpoint for the contract by binding it (using the binding definition, hence the name) to a network address. | * You deploy an endpoint for the contract by binding it (using the binding definition, hence the name) to a network address. | ||
+ | |||
+ | ==== Binding ==== | ||
+ | |||
+ | Bindings are nothing but the transport protocols that are used for the communication with the client application. WCF provides a wide range of transport protocols that can be used as in the requirements. | ||
+ | |||
+ | A binding has the following characteristics: | ||
+ | |||
+ | * Transport: Defines the base protocol to be used, like HTTP, Named Pipes, TCP and MSMQ are some of the protocols. | ||
+ | * Encoding (Optional): Three types of encodings are available, they are: | ||
+ | |||
+ | - Text Encoding | ||
+ | - Binary Encoding | ||
+ | - Message Transmission Optimization Mechanism (MTOM) | ||
+ | |||
+ | * Protocol (Optional): Defines the information to be used in the binding such as Security, transaction or reliable messaging capability. | ||
+ | |||
==== Types of Binding ==== | ==== Types of Binding ==== | ||
Ligne 71: | Ligne 87: | ||
*It provides full support for SOAP security, transaction and reliability. | *It provides full support for SOAP security, transaction and reliability. | ||
- | ==== Creation of various endpoints in configuration ==== | + | ==== Exercice : Creation of various endpoints in configuration with different kinds of bindings ==== |
Endpoints provide clients with access to the functionality a Windows Communication Foundation (WCF) service offers. You can define one or more endpoints for a service by using a combination of relative and absolute endpoint addresses, or if you do not define any service endpoints, the runtime provides some by default for you. | Endpoints provide clients with access to the functionality a Windows Communication Foundation (WCF) service offers. You can define one or more endpoints for a service by using a combination of relative and absolute endpoint addresses, or if you do not define any service endpoints, the runtime provides some by default for you. | ||
- | == Tutorial on Bindings == | + | |
- | ||| | + | |
* Take the calculator Web service (with and add and sub between two value) | * Take the calculator Web service (with and add and sub between two value) | ||
- | * Define two endpoints : one with basicHttpBinding and the other with wsHttpBinding | + | * Define two endpoints : one with basicHttpBinding and wsHttpBinding (two standard bindings for SOAP based web services) |
* What are the differences between both services now ? | * What are the differences between both services now ? | ||
* To test them write a console or a graphical client that propose add and sub operations on the two endpoints. | * To test them write a console or a graphical client that propose add and sub operations on the two endpoints. | ||