-
Notifications
You must be signed in to change notification settings - Fork 806
Open
Labels
enhancementNew feature or requestNew feature or request
Milestone
Description
Is your feature request related to a problem? Please describe.
Currently, GrpcClientFactoryOptions.Creator
can implement custom client generation, but the client type is not passed to the Creator
delegate, so we cannot generate a custom client.
The default activation process is to pass a type parameter to the IServiceProvider
when requesting a DefaultClientActivator
, so the client type is passed to the DefaultClientActivator
.
var defaultClientActivator = _serviceProvider.GetService<DefaultClientActivator<TClient>>(); |
Describe the solution you'd like
We want to receive the client's type in a custom delegate or make ClientActivator service replaceable.
public Func<CallInvoker, Type, object>? Creator { get; set; }
var c = clientFactoryOptions.Creator(callInvoker, typeof(TClient));
Additional context
Our MagicOnion project relies on Grpc.Net, but has its own implementation at the client layer.
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request