Source

core hello world / workshop / part_II.org

Full commit
Yaron Minsky 996e5f2 








Yaron Minsky 85769e3 















Yaron Minsky 71a5f7a 

* Approaches to Concurrent Programming
** Two classic approaches
 - Event-loops
 - Threads
** Async
 - Best of both
 - Synchronous reasoning
 - Ability to sequence operations
 - Still cooperative (so one thread can block the world)
* Basic types
** Execution model
** Deferred
** Monitor
** Pipe
* Simple Examples
 - interactive
 - [[file:async/manifest.ml][file:async/manifest.ml]]
 - file:async/pipe_manifest.ml
* Exercises: Async count_lines
 - Convert count_lines to use Async
 - Make sure to use =Command.async_basic= instead of =Command.basic=
* Code walkthrough: Client/Server Hello World
** Exercise
 - Add a new RPC for requesting the time of day (using Time.now).
* Code walkthrough: Message Broker
** Exercise
 Add a disconnect operation