Skip to content

Commit

Permalink
Log 1st chance exceptions in fan-out test
Browse files Browse the repository at this point in the history
  • Loading branch information
ReubenBond committed May 21, 2024
1 parent 169db61 commit e60d33e
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions test/Benchmarks/Ping/FanoutBenchmark.cs
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,8 @@ public FanoutBenchmark(int numSilos, bool startClient, bool grainsOnSecondariesO

_onCancelEvent = CancelPressed;
Console.CancelKeyPress += _onCancelEvent;
AppDomain.CurrentDomain.FirstChanceException += (object sender, System.Runtime.ExceptionServices.FirstChanceExceptionEventArgs e) => Console.WriteLine("FIRST CHANCE EXCEPTION: " + LogFormatter.PrintException(e.Exception));
AppDomain.CurrentDomain.UnhandledException += (object sender, UnhandledExceptionEventArgs e) => Console.WriteLine("UNHANDLED EXCEPTION: " + LogFormatter.PrintException((Exception)e.ExceptionObject));
}

private void CancelPressed(object sender, ConsoleCancelEventArgs e)
Expand Down

0 comments on commit e60d33e

Please sign in to comment.