public void Run([TimerTrigger("0 0 0,8,10,12,14,16,18,20,22 * * *")] TimerInfo myTimer, ILogger log) { try { log.LogInformation($"GetCounts started at: {DateTime.Now}"); _reportsService.CountReport(); log.LogInformation($"GetCounts completed at: {DateTime.Now}"); } catch (AggregateException exc) { log.LogError(exc.Flatten().ToString()); } catch (Exception ex) { log.LogError($"Unhandled error in GetCounts {ex}"); } }