public Task Log(MonitoringLogEntry logEntry) { ThreadPool.QueueUserWorkItem(async x => { var response = await _client.IndexAsync <StringResponse>("monitoring", logEntry.GetType().Name, logEntry.Id.ToString(), PostData.Serializable(logEntry)); CheckReponseSuccess(response, "monitoring"); }); return(Task.Delay(0)); }
public Task Log(MonitoringLogEntry data) { return(Task.WhenAll(_loggers.Select(x => x.Log(data)).ToArray())); }