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

feat: Load client config from arbitrary config block #1974

Merged
merged 3 commits into from
Sep 9, 2024

Conversation

johanandren
Copy link
Member

No description provided.

Copy link
Member

@patriknw patriknw left a comment

Choose a reason for hiding this comment

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

thanks, that would be useful

runtime/src/main/scala/akka/grpc/GrpcClientSettings.scala Outdated Show resolved Hide resolved
@johanandren johanandren marked this pull request as ready for review September 6, 2024 13:47
Copy link
Member

@patriknw patriknw left a comment

Choose a reason for hiding this comment

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

LGTM

def fromConfig(clientName: String, config: Config)(
implicit actorSystem: ClassicActorSystemProvider): GrpcClientSettings = {
// Use config named "*" by default
val defaultServiceConfig = actorSystem.classicSystem.settings.config.getConfig("akka.grpc.client.\"*\"")
Copy link
Member

Choose a reason for hiding this comment

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

I was considering if this should be config.withFallback(actorSystem.classicSystem.settings.config) in case the given config also overrides default config, but fine to not support that kind of override.

Copy link
Member Author

Choose a reason for hiding this comment

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

Hmm, yeah, maybe not a bad idea.

Copy link
Member Author

Choose a reason for hiding this comment

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

Let's leave that and revisit in case we figure out that it is very useful.

@johanandren johanandren merged commit ee25c69 into main Sep 9, 2024
12 checks passed
@johanandren johanandren deleted the wip-client-settings-from-arbitrary-config branch September 9, 2024 15:30
@johanandren johanandren added this to the 2.4.4 milestone Sep 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants