Making takeAsync and collectAsync deterministic.