Generalize Pipe pattern for async processing of tasks in order