public async Task RunAsync() { Console.WriteLine("Preparing..."); var swg = Stopwatch.StartNew(); var sw = Stopwatch.StartNew(); await Task.WhenAll(_setupServices.Select(s => s.SetupAsync())); Console.WriteLine($"Preparing finished: {sw.Elapsed.TotalSeconds} sec"); Console.WriteLine("Aggregating data..."); sw.Restart(); var aggregationResult = await _aggregatorService.AggregateDataAsync(); Console.WriteLine($"Aggregating data finished: {sw.Elapsed.TotalSeconds} sec"); Console.WriteLine("Exporting..."); sw.Restart(); await _exportService.ExportAsync(aggregationResult); Console.WriteLine($"Exporting finished: {sw.Elapsed.TotalSeconds} sec"); Console.WriteLine($"Took {swg.Elapsed.TotalSeconds} sec"); }