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

Credential injection dual filter support #35194

Closed

Conversation

juanmolle
Copy link
Contributor

@juanmolle juanmolle commented Jul 15, 2024

Convert credential injection filter in dual filter

Risk Level: low
Testing: yes
Docs Changes: n/a
Release Notes: yes
Platform Specific Features: No

Copy link

As a reminder, PRs marked as draft will not be automatically assigned reviewers,
or be handled by maintainer-oncall triage.

Please mark your PR as ready when you want it to be reviewed!

🐱

Caused by: #35194 was opened by juanmolle.

see: more, trace.

@juanmolle
Copy link
Contributor Author

I would like to have feedback before proceed with unit test and integration tests

hdrs = ["server_factory_context.h"],
srcs = [
"server_factory_context.cc",
"transport_socket_factory_context.cc",
Copy link
Contributor Author

Choose a reason for hiding this comment

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

this is to avoid circular dependencies between both mocks. probably it should be only one.

Signed-off-by: Juan Manuel Ollé <[email protected]>
@juanmolle
Copy link
Contributor Author

/retest

Signed-off-by: Juan Manuel Ollé <[email protected]>
Signed-off-by: Juan Manuel Ollé <[email protected]>
Signed-off-by: Juan Manuel Ollé <[email protected]>
Signed-off-by: Juan Manuel Ollé <[email protected]>
@@ -1045,8 +1045,10 @@ void ClusterManagerImpl::updateClusterCounts() {
}

ThreadLocalCluster* ClusterManagerImpl::getThreadLocalCluster(absl::string_view cluster) {
if (!tls_.get()) {
return nullptr;
}
Copy link
Contributor Author

Choose a reason for hiding this comment

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

during upstream filter initialization, the filter tries to do a warmup and perform a request. this object is not initialized at that moment. Is there a better solution for this?

FilterConfigSharedPtr config = std::make_shared<FilterConfig>(
std::move(credential_injector), proto_config.overwrite(),
proto_config.allow_request_without_credential(),
dual_info.is_upstream ? "credential_injector." : stats_prefix + "credential_injector.",
Copy link
Contributor Author

Choose a reason for hiding this comment

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

this is another side effect, it is called twice. without this change we get cluster.cluster_0.cluster.cluster_0credential_injector

@juanmolle juanmolle marked this pull request as ready for review July 18, 2024 17:22
@yanavlasov
Copy link
Contributor

/wait-any

Copy link

This pull request has been automatically marked as stale because it has not had activity in the last 30 days. It will be closed in 7 days if no further activity occurs. Please feel free to give a status update now, ping for review, or re-open when it's ready. Thank you for your contributions!

@github-actions github-actions bot added the stale stalebot believes this issue/PR has not been touched recently label Aug 22, 2024
Copy link

This pull request has been automatically closed because it has not had activity in the last 37 days. Please feel free to give a status update now, ping for review, or re-open when it's ready. Thank you for your contributions!

@github-actions github-actions bot closed this Aug 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
stale stalebot believes this issue/PR has not been touched recently waiting:any
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants