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

improve certificate matching performance #4186

Merged
merged 1 commit into from May 23, 2023

Conversation

calebdoxsey
Copy link
Contributor

Summary

Currently for every route we query for all the certificates, which results in a linear scan of all the certificates to see if anything matches * (which will never happen). This updates the code to only query for all the certificates once, and to remove the inner linear scan for matching * certificates to always generate a *.

Related issues

Checklist

  • reference any related issues
  • updated unit tests
  • add appropriate tag (improvement / bug / etc)
  • ready for review

@calebdoxsey calebdoxsey requested a review from a team as a code owner May 23, 2023 00:44
@calebdoxsey calebdoxsey requested a review from wasaga May 23, 2023 00:44
@coveralls
Copy link

Coverage Status

Coverage: 63.528% (-0.2%) from 63.726% when pulling d68cb75 on cdoxsey/faster-cert-matching into d6e1f3a on main.

@desimone desimone requested a review from kenjenkins May 23, 2023 02:32
@desimone
Copy link
Contributor

Is this a backport candidate?

@calebdoxsey calebdoxsey merged commit e3b2b39 into main May 23, 2023
14 checks passed
@calebdoxsey calebdoxsey deleted the cdoxsey/faster-cert-matching branch May 23, 2023 13:39
calebdoxsey added a commit that referenced this pull request May 23, 2023
improve certificate matching performance (#4186)

Co-authored-by: Caleb Doxsey <cdoxsey@pomerium.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants