3. Pierre :
Worked in the Microsoft space for 20 years
Speaker, trainer, developer, architect, …
Primarily interested inWeb topics
Identity, architecture,WS-*, interop, cloud, …
Recent interop/OSS activity
Worked on drupal for Sql server project
Works on automated drupal testing onWindows
Speaker at major PHP events
▪ DrupalCon, PHP Forum, Symfony live
blog.couzy.com / pierre.couzy@microsoft.com
5. C# is an imperative language
Which is nice
Except for a few things
Splitting data manipulation between your code
and your data store
Coding data manipulation
Applying new manipulation patterns to existing
data
6.
7. Express more intent, less implementation
Easy composition
Strong typing
This is subject to hot debate
.. And out of scope today
Be as declarative as possible within the limits
imposed by an imperative language
8.
9. Lazy evaluation
If we step into this code, we see LINQ triggers its magic on
demand
Easy composition
If we add new clauses after the LINQ expression is built
but before it’s consumed, we simply merge the additions
to the existing expression
So far, we’ve worked on objects
Which is how many naive LINQ implementations work :
synchronously pipelining methods calls on collections
LINQ has a lot more to it
But this not on our todo today
11. Imperative synchronous programming was
hard enough to call for LINQ
And yet we’ve been doing this for decades
Event-based (or async) patterns are a
complete mess today
Unconvinced ? Let’s see…
12. We were pulling data from an enumerable
We will push data from an observable
We were lazy (doing just in time)
We will receive data as a stream (just in time)
We were composable
We’ll stay that way
13. It’s a source
Our code will subscribe to that source
Duh, difference with an event handler ?
Observable sequences are first-class
constructs
Provide a layer of abstraction
Much better for testing
Allows for much more scenarios
14. A sequence is more than a list of ..
It can fail
It can end
The observer , when it subscribes, can
subscribe to those three conditions
15. Observables allow you to manipulate a
chronology of events as a list.
And we can apply operators to lists.
This is called a workflow.
16. LINQ describes an iteration workflow (pull-
based), with composition, so that the
implementation does not obfuscate the
intention,
Rx describes an event-based workflow (push-
based), with composition, so that the
implementation does not obfuscate the
intention.