diff --git a/docs/new.json b/docs/new.json deleted file mode 100644 index 69e021678d052f0f868a24a39ab818911a6b47c5..0000000000000000000000000000000000000000 --- a/docs/new.json +++ /dev/null @@ -1,22 +0,0 @@ -{ - "name": "example", - "cacheNamespace": "login", - "cacheScope": "user", - "groups": [ - { - "execution": "sequential", - "tasks": [ - "task1", - "task2" - ] - }, - { - "execution": "parallel", - "tasks": [ - "task3", - "task4", - "task5" - ] - } - ] -} \ No newline at end of file diff --git a/internal/listexecutor/listexecutor.go b/internal/listexecutor/listexecutor.go index a2a4db65e39ebf8266593b993296d47577218a3d..fd0247af2660e008b25107c76014e7f16ad5c280 100644 --- a/internal/listexecutor/listexecutor.go +++ b/internal/listexecutor/listexecutor.go @@ -123,13 +123,12 @@ func (l *ListExecutor) Execute(ctx context.Context, list *tasklist.TaskList) { list.StartTime = time.Now() // execute groups sequentially - for i, group := range list.Groups { - if err := l.executeGroup(ctx, &group); err != nil { + for i, _ := range list.Groups { + if err := l.executeGroup(ctx, &list.Groups[i]); err != nil { logger.Error("error executing group", zap.Error(err)) - group.State = taskpkg.Failed + list.Groups[i].State = taskpkg.Failed list.State = taskpkg.Failed } - list.Groups[i] = group } if list.State != taskpkg.Failed {