reverse-proxy icon indicating copy to clipboard operation
reverse-proxy copied to clipboard

crash when BackgroundHostedService can not reach kubernetes API server

Open witskeeper opened this issue 2 years ago • 0 comments

Describe the bug

application crash when BackgroundHostedService can not reach kubernetes API server.

To Reproduce

What steps can we follow to reproduce the issue?

when use a unreachable kubernetes API server, the application will stop when connection timeout.

Got Exceptions? Include both the message and the stack trace

在 System.Net.Http.HttpConnectionPool.<ConnectToTcpHostAsync>d__99.MoveNext()
在 System.Threading.Tasks.ValueTask`1.get_Result()
在 System.Net.Http.HttpConnectionPool.<ConnectAsync>d__98.MoveNext()
在 System.Threading.Tasks.ValueTask`1.get_Result()
在 System.Net.Http.HttpConnectionPool.<AddHttp2ConnectionAsync>d__78.MoveNext()
在 System.Threading.Tasks.TaskCompletionSourceWithCancellation`1.<WaitWithCancellationAsync>d__1.MoveNext()
在 System.Threading.Tasks.ValueTask`1.get_Result()
在 System.Net.Http.HttpConnectionPool.HttpConnectionWaiter`1.<WaitForConnectionAsync>d__5.MoveNext()
在 System.Threading.Tasks.ValueTask`1.get_Result()
在 System.Net.Http.HttpConnectionPool.<SendWithVersionDetectionAndRetryAsync>d__84.MoveNext()
在 System.Net.Http.DiagnosticsHandler.<SendAsyncCore>d__10.MoveNext()
在 System.Threading.Tasks.ValueTask`1.get_Result()
在 System.Net.Http.RedirectHandler.<SendAsync>d__4.MoveNext()
在 System.Net.Http.HttpClient.<<SendAsync>g__Core|83_0>d.MoveNext()
在 k8s.Kubernetes.<SendRequestRaw>d__39.MoveNext()
在 k8s.AbstractKubernetes.<k8s-ICoreV1Operations-ListServiceForAllNamespacesWithHttpMessagesAsync>d__210.MoveNext()
在 Yarp.Kubernetes.Controller.Client.ResourceInformer`2.<ListAsync>d__22.MoveNext()
在 Yarp.Kubernetes.Controller.Client.ResourceInformer`2.<RunAsync>d__19.MoveNext()
在 Yarp.Kubernetes.Controller.Hosting.BackgroundHostedService.<<StartAsync>g__CallRunAsync|11_0>d.MoveNext()
在 Yarp.Kubernetes.Controller.Hosting.BackgroundHostedService.<StopAsync>d__12.MoveNext()
在 Microsoft.Extensions.Hosting.Internal.Host.<StopAsync>d__14.MoveNext()

Further technical details

  • Include the version of the packages you are using
  • The platform (Linux/macOS/Windows)

witskeeper avatar Nov 22 '22 15:11 witskeeper