collectOne
authorYunqiao Zhang <yunqiao@fb.com>
Fri, 26 Aug 2016 19:53:24 +0000 (12:53 -0700)
committerFacebook Github Bot 9 <facebook-github-bot-9-bot@fb.com>
Fri, 26 Aug 2016 20:08:27 +0000 (13:08 -0700)
commitda9e05e8a7d6667424bdffcd10086cc9a85ff1a9
tree9ad91e64ff2891c92fe2e87a4ce1bf916d0ba69a
parente0ac799a799a72413a1b4b74b1b4d4f3cb64259d
collectOne

Summary:
The resultant future of collectOne will be fulfilled when the first one of
the future in the list completes without exception. If all input futures throws
exception, the resultant future will get the last exception that was thrown.

Reviewed By: andriigrynenko

Differential Revision: D3764760

fbshipit-source-id: 76484254e35182eddc8266865853d65c28170f82
folly/futures/Future-inl.h
folly/futures/helpers.h
folly/futures/test/CollectTest.cpp