Run http request on separate thread. (#545)
This commit is contained in:
parent
10f0f7b2ee
commit
3d167c1e6c
|
|
@ -299,12 +299,12 @@
|
||||||
<application name="Active Server Pages" groupId="ASP" />
|
<application name="Active Server Pages" groupId="ASP" />
|
||||||
</applicationDependencies>
|
</applicationDependencies>
|
||||||
<authentication>
|
<authentication>
|
||||||
<anonymousAuthentication enabled="false" userName="" />
|
<anonymousAuthentication enabled="true" userName="" />
|
||||||
<basicAuthentication enabled="false" />
|
<basicAuthentication enabled="false" />
|
||||||
<clientCertificateMappingAuthentication enabled="false" />
|
<clientCertificateMappingAuthentication enabled="false" />
|
||||||
<digestAuthentication enabled="false" />
|
<digestAuthentication enabled="false" />
|
||||||
<iisClientCertificateMappingAuthentication enabled="false"></iisClientCertificateMappingAuthentication>
|
<iisClientCertificateMappingAuthentication enabled="false"></iisClientCertificateMappingAuthentication>
|
||||||
<windowsAuthentication enabled="true">
|
<windowsAuthentication enabled="false">
|
||||||
<providers>
|
<providers>
|
||||||
<add value="Negotiate" />
|
<add value="Negotiate" />
|
||||||
<add value="NTLM" />
|
<add value="NTLM" />
|
||||||
|
|
|
||||||
|
|
@ -80,14 +80,7 @@ namespace Microsoft.AspNetCore.Server.IISIntegration
|
||||||
|
|
||||||
var context = server._iisContextFactory.CreateHttpContext(pInProcessHandler);
|
var context = server._iisContextFactory.CreateHttpContext(pInProcessHandler);
|
||||||
|
|
||||||
var task = context.ProcessRequestAsync();
|
var task = Task.Run(() => context.ProcessRequestAsync());
|
||||||
|
|
||||||
// This should never fail
|
|
||||||
if (task.IsCompleted)
|
|
||||||
{
|
|
||||||
context.Dispose();
|
|
||||||
return ConvertRequestCompletionResults(task.Result);
|
|
||||||
}
|
|
||||||
|
|
||||||
task.ContinueWith((t, state) => CompleteRequest((IISHttpContext)state, t), context);
|
task.ContinueWith((t, state) => CompleteRequest((IISHttpContext)state, t), context);
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue