Skip to content

Perf-up the AuthZ! - #43268

Merged
Tratcher merged 4 commits into
dotnet:mainfrom
Kahbazi:kahbazi/AuthPerf
Aug 18, 2022
Merged

Tratcher merged 4 commits into
dotnet:mainfrom
Kahbazi:kahbazi/AuthPerf

Conversation

@Kahbazi

@Kahbazi Kahbazi commented Aug 13, 2022

Copy link
Copy Markdown
Member
  • Reuse the AuthenticateResult, AuthorizationResult, AuthorizationFailure, DenyAnonymousAuthorizationRequirement instances
  • Store Task<Policy> to avoid creating a new Task on each call.
  • Use foreach instead of Any in authz requirements to avoid the closure allocations.

@ghost ghost added the community-contribution Indicates that the PR has been added by a community member label Aug 13, 2022
@ghost

ghost commented Aug 13, 2022

Copy link
Copy Markdown

Thanks for your PR, @Kahbazi. Someone from the team will get assigned to your PR shortly and we'll get it reviewed.

@davidfowl

Copy link
Copy Markdown
Member

Very nice!

@Tratcher
Tratcher merged commit 4db440d into dotnet:main Aug 18, 2022
@Tratcher

Copy link
Copy Markdown
Member

Thanks

@ghost ghost added this to the 8.0-alpha1 milestone Aug 18, 2022
@Kahbazi
Kahbazi deleted the kahbazi/AuthPerf branch August 19, 2022 07:34
@davidfowl davidfowl added the Perf label Aug 26, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

community-contribution Indicates that the PR has been added by a community member Perf

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants