示例#1
0
 private async Task <IReadOnlyCollection <MethodInvocationResult> > InvokeNonExclusiveMethodsAsync(
     object message,
     bool executeAsync) =>
 (await _subscribedMethodsCache.GetNonExclusiveMethods(message)
  .ParallelSelectAsync(
      method =>
      SubscribedMethodInvoker.InvokeAsync(
          method,
          message,
          _serviceProvider,
          executeAsync))
  .ConfigureAwait(false))
 .ToList();
示例#2
0
 private SubscribedMethodInvoker GetMethodInvoker() =>
 _methodInvoker ?? (_methodInvoker = _serviceProvider.GetRequiredService <SubscribedMethodInvoker>());