ASP.NET – InvalidOperationException: Synchronous operations are disallowed

Problem You’re trying to do synchronous IO operations in ASP.NET and you get the following exception: System.InvalidOperationException: ‘Synchronous operations are disallowed. Call WriteAsync or set AllowSynchronousIO to true The reason you’re getting this is because server option AllowSynchronousIO is false. Starting in ASP.NET Core 3.0, this is false by default. Solution Microsoft turned this setting … Read more ASP.NET – InvalidOperationException: Synchronous operations are disallowed