I am trying to asynchronously create a new AsyncUnaryCall
instance that wraps the original interecepted one.
the problem is the poor design of interceptor base class which does not allow async method interceptors. (as described here: https://github.com/grpc/grpc-dotnet/issues/694)
to get the idea, here is what is want to achieve:
public override AsyncUnaryCall<TResponse> AsyncUnaryCall<TRequest, TResponse>(TRequest request, ClientInterceptorContext<TRequest, TResponse> context, AsyncUnaryCallContinuation<TRequest, TResponse> continuation)
{
var result = await MyAsyncStuff(); // if we can not await, what is the alternative?
return new AsyncUnaryCall<TResponse>(paramters);
}