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

Add certificate provider registry implementation #24080

Merged
merged 1 commit into from
Sep 9, 2020

Conversation

yashykt
Copy link
Member

@yashykt yashykt commented Sep 8, 2020

This change is Reviewable

@yashykt yashykt added the release notes: no Indicates if PR should not be in release notes label Sep 8, 2020
@yashykt yashykt requested a review from markdroth September 8, 2020 21:51
Copy link
Member

@markdroth markdroth left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just one minor suggestion. Otherwise, looks great!

Reviewed 20 of 20 files at r1.
Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @yashykt)


src/core/ext/xds/certificate_provider_registry.cc, line 57 at r1 (raw file):

  // hurting performance (which is unlikely, since these allocations
  // only occur at gRPC initialization time).
  absl::InlinedVector<std::unique_ptr<CertificateProviderFactory>, 3>

Why not just use std::map<> here? That would make lookups more efficient at run-time.

Copy link
Member Author

@yashykt yashykt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @markdroth)


src/core/ext/xds/certificate_provider_registry.cc, line 57 at r1 (raw file):

Previously, markdroth (Mark D. Roth) wrote…

Why not just use std::map<> here? That would make lookups more efficient at run-time.

I don't have data for this, but from sounds like for a small number of elements vectors are faster than std::map.

Copy link
Member

@markdroth markdroth left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewable status: :shipit: complete! all files reviewed, all discussions resolved


src/core/ext/xds/certificate_provider_registry.cc, line 57 at r1 (raw file):

Previously, yashykt (Yash Tibrewal) wrote…

I don't have data for this, but from sounds like for a small number of elements vectors are faster than std::map.

A map seems more natural to me, but I guess it doesn't really matter. This is fine for now.

@yashykt
Copy link
Member Author

yashykt commented Sep 9, 2020

Issues: #24092, #24093

@yashykt
Copy link
Member Author

yashykt commented Sep 9, 2020

Thanks for reviewing!

@yashykt yashykt merged commit 24ba65d into grpc:master Sep 9, 2020
@yashykt yashykt deleted the caregimpl branch May 18, 2023 20:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release notes: no Indicates if PR should not be in release notes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants