Skip to content

When events fail to send, after some time sending stops altogether #3

@RedShift1

Description

@RedShift1

When a network error occurs, HTTP failure gets logged but after a while the program stops sending events altogether. Example:

2020-11-01 01:00:39.679 -04:00 [ERR] Failed to handle an event log entry
System.Net.Http.HttpRequestException: An error occurred while sending the request. ---> System.Net.WebException: The underlying connection was closed: The connection was closed unexpectedly.
   at System.Net.HttpWebRequest.EndGetResponse(IAsyncResult asyncResult)
   at System.Net.Http.HttpClientHandler.GetResponseCallback(IAsyncResult ar)
   --- End of inner exception stack trace ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at Seq.Client.EventLog.SeqApi.<PostRawEvents>d__1.MoveNext() in D:\a\1\s\src\Seq.Client.EventLog\SeqApi.cs:line 27
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at Seq.Client.EventLog.EventLogListener.<HandleEventLogEntry>d__34.MoveNext() in D:\a\1\s\src\Seq.Client.EventLog\EventLogListener.cs:line 148
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at Seq.Client.EventLog.EventLogListener.OnEntryWritten(Object sender, EntryWrittenEventArgs args) in D:\a\1\s\src\Seq.Client.EventLog\EventLogListener.cs:line 125
2020-11-01 01:45:01.622 -05:00 [ERR] Received failure status code "BadGateway" from Seq: Proxy Error

I would expect the program to exit so it can automatically be restarted by the OS instead of hanging in limbo.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions