Skip to content

Instantly share code, notes, and snippets.

@mikhailshilkov
Created December 19, 2018 23:03
Show Gist options
  • Save mikhailshilkov/070851a206f05b23491ee9a26d9a25b5 to your computer and use it in GitHub Desktop.
Save mikhailshilkov/070851a206f05b23491ee9a26d9a25b5 to your computer and use it in GitHub Desktop.
let workflow wishlist = orchestrator {
let! matches =
wishlist.Wishes
|> List.map (Activity.call findMatchingGiftActivity)
|> Activity.all
let! gift = Activity.call pickGiftActivity (List.concat matches)
let reservation = { Kid = wishlist.Kid; Product = gift }
do! Activity.call reserveActivity reservation
return reservation
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment