-
Type: Improvement
-
Resolution: Unresolved
-
Priority: Major - P3
-
None
-
Affects Version/s: None
-
Component/s: None
-
Server Programmability
The implementation for Future::tapAll currently constructs a StatusWith<T> using T's copy constructor, which it then passes to the provided callback. This is potentially wasteful, as tapAll callbacks often do not require ownership of the result. Furthermore, this prevents one from registering a tapAll callback on a Future whose result type is non-copyable.
If possible, we should relax this constraint on Future::tapAll.