fix: resolve slopwatch issues — add logging to empty catches and eliminate test timing delays
Replace empty catch blocks with meaningful log statements in NatsServer, NatsClient, and Program. Add WaitForReadyAsync() to NatsServer for deterministic server startup. Replace Task.Delay/Thread.Sleep in tests with PING/PONG protocol flush and SubscribeCoreAsync for reliable subscription synchronization.
This commit is contained in:
@@ -40,7 +40,10 @@ try
|
||||
{
|
||||
await server.StartAsync(cts.Token);
|
||||
}
|
||||
catch (OperationCanceledException) { }
|
||||
catch (OperationCanceledException)
|
||||
{
|
||||
Log.Information("Server shutdown requested");
|
||||
}
|
||||
finally
|
||||
{
|
||||
Log.CloseAndFlush();
|
||||
|
||||
Reference in New Issue
Block a user