dataobjects-net icon indicating copy to clipboard operation
dataobjects-net copied to clipboard

Disable `.ConfigureAwait(false)` by conditional compilation constant `DO_CONFIGURE_AWAIT_FALSE`

Open SergeiPavlov opened this issue 1 year ago • 0 comments

In typical ASP.NET apps .ConfigureAwait(false) creates unnecessary overhead (a few nanoseconds). .ConfigureAwait(false) makes sense mostly for UI applications, with non-null Synchronization Context

This can be switched off by setting environment variable DO_CONFIGURE_AWAIT_FALSE=false at compile time

SergeiPavlov avatar Aug 24 '23 21:08 SergeiPavlov