We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7f00aff commit 30aa016Copy full SHA for 30aa016
src/Serilog.Sinks.Grafana.Loki/LokiSink.cs
@@ -134,12 +134,14 @@ private async Task OnTick()
134
}
135
else
136
{
137
- _connectionSchedule.MarkFailure();
138
-
139
SelfLog.WriteLine(
140
- "Received failure on HTTP shipping {0}: {1}",
141
- response.StatusCode,
142
- await response.Content.ReadAsStringAsync().ConfigureAwait(false));
+ "Received failure on HTTP shipping ({0}): {1}. {2} log events will be dropped",
+ (int)response.StatusCode,
+ await response.Content.ReadAsStringAsync().ConfigureAwait(false),
+ _waitingBatch.Count);
+
143
+ _connectionSchedule.MarkFailure();
144
+ _waitingBatch.Clear();
145
146
break;
147
0 commit comments