-
Task
-
Resolution: Done
-
Major
-
9.0.0.Beta2
-
None
Replicated read benchmarks show a significant amount of time spent in BasicInvocationStage.toInvocationStage().
We can make visitCommand return an Object instead of an InvocationStage, and that return value can be cast to an InvocationStage when a callback is needed. We can't call thenApply() etc. directly on an Object, but we can combine invokeNext(ctx, command).thenApply(function) into invokeNextThenApply(ctx, command, function).