I support the ASP.NET web application, which causes the network connection of the user to reset within a few seconds when it executes the procedure. Thus, the page request expires on the user side, since they never receive the response of the web application (the connection dies before it receives the response packet).
To solve this problem, I thought that the ASP.NET page performs an asynchronous function including Thread.Sleep(5000); // sleep for 5 seconds before executing the connection reset. Thus, the browser takes 5 seconds to get a response to the page before their connection is reset.
I have problems using Thread.Sleep and asynchronous functions in ASP.NET. I have never tried to do this before, so I'm not sure about the possible problems that may arise. Does anyone see potential problems starting an asynchronous thread that Thread.Sleepan ASP.NET application contains ? If so, can you think of a better solution?
regex source
share