Multitasking, Golang, Software Development, Concurrency, Parallel Computing.
"golang.org/x/sync/errgroup" ) // errFailure some custom error. var errFailure = errors.New("some error") func main() { // Create errgroup. group := errgroup.Group{} // Run first task. group.Go(func() error { time.Sleep(5 * time.Second) fmt.Println("doing some work 1") return nil }) // Run second