cours:service_oriented_computing_and_web_services_2017_2018:lab_eventing_and_wstutorial:publish_subscribe_pattern_for_eventing_with_web_services
Différences
Ci-dessous, les différences entre deux révisions de la page.
Les deux révisions précédentesRévision précédenteProchaine révision | Révision précédente | ||
cours:service_oriented_computing_and_web_services_2017_2018:lab_eventing_and_wstutorial:publish_subscribe_pattern_for_eventing_with_web_services [2018/03/29 08:22] – [Create the Client Application] tigli | cours:service_oriented_computing_and_web_services_2017_2018:lab_eventing_and_wstutorial:publish_subscribe_pattern_for_eventing_with_web_services [2018/03/29 09:33] (Version actuelle) – [Create WCF Service Library (EventsLib.dll)] tigli | ||
---|---|---|---|
Ligne 1: | Ligne 1: | ||
- | ====== Event Based Communication and Architecture with web services | + | ====== Event based Communication and Event driven |
- | ===== Your first step by step eventing communications between Web service and Client ===== | + | <note warning> |
+ | The solution of the first part of this tutorial is provided below. | ||
+ | |||
+ | Add the solution(s) of the second part of this tutorial on your Github repository ! | ||
+ | </ | ||
+ | |||
+ | ===== Introduction : Why Event driven Architecture ? ===== | ||
+ | |||
+ | |||
+ | {{ : | ||
+ | |||
+ | Classical Request–response, | ||
+ | |||
+ | Using request/ | ||
+ | |||
+ | A typical domain with such a problem is Internet of Things like for example sensors networks. | ||
+ | In fact it's easy to understand that for N sensors, the client must send N requests periodically to test if one sensor measure changed since last requests ! | ||
+ | |||
+ | Event-driven architecture (EDA), is a software architecture pattern promoting the production, detection, consumption of, and reaction to events. | ||
+ | |||
+ | An event can be defined as "a significant change in state" | ||
+ | |||
+ | Some Middleware like [[https:// | ||
+ | |||
+ | |||
+ | ===== PART 1 : Your first step by step eventing communications between Web service and Client ===== | ||
==== Events Introduction ==== | ==== Events Introduction ==== | ||
Ligne 24: | Ligne 49: | ||
* **.Net Framework Class Library** (EventsLib.dll): | * **.Net Framework Class Library** (EventsLib.dll): | ||
- | * **Console | + | * **Console Application** to host the WCF Service Library EventsLibHost.exe): |
- | * | + | |
On the client side : | On the client side : | ||
- | * Console | + | |
<note warning> | <note warning> | ||
Ligne 45: | Ligne 69: | ||
=== Defining Interface ICalcServiceEvents (ICalcServiceEvents.cs) === | === Defining Interface ICalcServiceEvents (ICalcServiceEvents.cs) === | ||
- | + | ||| | |
- | ** Exercice: ** | + | |
Now Let's define interface for the events published by the service. | Now Let's define interface for the events published by the service. | ||
Ligne 335: | Ligne 358: | ||
* Build and execute, and here is the output: | * Build and execute, and here is the output: | ||
+ | |||
+ | ===== Correction ===== | ||
+ | |||
<note warning> | <note warning> | ||
+ | Here, is the solution of the first part | ||
</ | </ | ||
- | |||
- | ===== Correction ===== | ||
{{: | {{: | ||
Ligne 363: | Ligne 388: | ||
=== Action< | === Action< | ||
https:// | https:// | ||
- | ===== Advanced use of Eventing ===== | + | ===== PART 2 : Advanced use of Eventing ===== |
Thanks to the previous example, create a central WS that accept data modification from " | Thanks to the previous example, create a central WS that accept data modification from " | ||
Test it with a simple shared data like a count value, with one pupblisher and various subscribers. | Test it with a simple shared data like a count value, with one pupblisher and various subscribers. | ||
cours/service_oriented_computing_and_web_services_2017_2018/lab_eventing_and_wstutorial/publish_subscribe_pattern_for_eventing_with_web_services.1522311757.txt.gz · Dernière modification : 2018/03/29 08:22 de tigli