Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clean up async timeout extension methods V2 #31768

Closed
wants to merge 7 commits into from

Conversation

ladeak
Copy link
Contributor

@ladeak ladeak commented Apr 13, 2021

  • Consolidating all Timeout extension methods in Shared folder

  • Adding a new compiler condition to set namespace and visibility of the TaskExtensions to distinguish http2cat and Microsoft.AspNetCore.Testing usage. Both projects reference the Shared file.

  • http2cat uses namespace System.Threading.Tasks.Extensions so that the catch block in TimeoutAfter method can filter catching TimeoutException based on the Source property.

  • Functional/Integration tests add file reference to Shared TaskExtensions (as they do for http2cat as well) to make http2cat\Http2Utilities.cs compile without referencing Microsoft.AspNetCore.Testing

  • Removing WithTimeout, OrTimeout and DefaultTimeout definitions in other projects

  • Using DefaultTimeout consistently instead of WithTimeout and OrTimeout

  • Keeping Timeout duration definitions unique to projects (IIS) which has larger than the usual 30 seconds elsewhere

  • Adding NETCore TargetFramwork to Microsoft.AspNetCore.Testing so .NET6 bits can be used

  • Using WaitAsync in NET6 and with if-else compiler switches to fallback to existing implementation

Addresses #16620

@ghost ghost added the community-contribution Indicates that the PR has been added by a community member label Apr 13, 2021
@ladeak
Copy link
Contributor Author

ladeak commented Apr 13, 2021

V1 version: #31671 see for further details and discussions.

@Pilchie Pilchie added area-runtime area-signalr Includes: SignalR clients and servers labels Apr 14, 2021
@ladeak
Copy link
Contributor Author

ladeak commented Apr 16, 2021

I will close and cancel this PR, and evolve the one referred as v1.

@ladeak ladeak closed this Apr 16, 2021
@ghost
Copy link

ghost commented Apr 16, 2021

Hi @ladeak. It looks like you just commented on a closed PR. The team will most probably miss it. If you'd like to bring something important up to their attention, consider filing a new issue and add enough details to build context.

@ladeak ladeak deleted the ladeak_WaitAsyncV2 branch April 16, 2021 06:57
@amcasey amcasey added area-middleware Includes: URL rewrite, redirect, response cache/compression, session, and other general middlesware area-networking Includes servers, yarp, json patch, bedrock, websockets, http client factory, and http abstractions and removed area-runtime labels Jun 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-middleware Includes: URL rewrite, redirect, response cache/compression, session, and other general middlesware area-networking Includes servers, yarp, json patch, bedrock, websockets, http client factory, and http abstractions area-signalr Includes: SignalR clients and servers community-contribution Indicates that the PR has been added by a community member
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants