1
Vote

Add Scatter + Gather

description

Add a stage to not only scatter the processing onto parallel threads, but which also allows to gather the results later on. Think of a flow which receives a directory name and is supposed to produce the number of words in all files in this directory. Such a flow could scatter word counting per file - but then would need to gather all those word counts in order to total them.
 
It could maybe look like this:
 
Flow<string>.Scatter<string>(FindAllFilesInDirectory)
.Do<int>(CountWordsInFile)
.Gather<int>(CalculateTotal)
 
With the use of the CCR multi item receiver this should not be a big problem.

comments