Adds conditional middleware that runs a sub-pipeline only when the
asynchronous predicate returns true.
IProcessMiddlewareBuilder UseWhen(Func<InvocationContext, Task<bool>> predicate, Action<IProcessMiddlewareBuilder> configuration)
The async condition evaluated before each invocation.
An action that configures the sub-pipeline builder.