From 9b5c1b2bb69cf3c13c1d2c9cdbd5f92464cc7312 Mon Sep 17 00:00:00 2001 From: Mart Lubbers Date: Mon, 2 Mar 2020 16:33:32 +0100 Subject: [PATCH] . --- cloudiTasks/cloudiTasks.icl | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/cloudiTasks/cloudiTasks.icl b/cloudiTasks/cloudiTasks.icl index 2693038..b80d5b0 100644 --- a/cloudiTasks/cloudiTasks.icl +++ b/cloudiTasks/cloudiTasks.icl @@ -3,7 +3,6 @@ module cloudiTasks import Data.Func, Data.Functor, Data.Tuple import StdEnv import iTasks -import iTasks.Extensions.DateTime Start w = doTasks master w @@ -12,10 +11,10 @@ master = get applicationOptions >>- \eo->traceValue ("Master started on port " +++ toString eo.serverPort) // >-| asyncTask (ExistingNode "localhost" 9099) (blockWait 5) - >-| asyncTask (PrivateNode 9099) (blockWait 5) +// >-| asyncTask "localhost" 9090 (blockWait 5) // >-| asyncTask (PrivateNode 9099) (traceValue 5 >-| traceValue 42) -// >-| asyncTask (PrivateNode 9099) (updateInformation [] 42) -// >-| sleepSortPar [5,1,3,8] +// >-| asyncTaskSpawn 9099 (return 42) + >-| sleepSortPar [5,1,3,8] >&^ viewSharedInformation [] @! () @@ -30,11 +29,11 @@ where sleepSortPar :: [Int] -> Task [Int] sleepSortPar numbers = parallel [ (Embedded, \stl-> - asyncTask (PrivateNode port) (blockWait num) + asyncTaskSpawn port (blockWait num) >-| appendTask Embedded (\_->return num) stl @? const NoValue) \\ num <- numbers - & port <- [9091..9099] + & port <- [9092..9099] ] [] @? \tv->case tv of NoValue = NoValue (Value ts _) -- 2.20.1