Open austinjones opened 4 years ago
If one of the inputs to Task::spawn was &Bus, lifeline could create and execute a group of message receivers, not just one.
Lifeline would take the bus, and a FnMut spawn function which receives &Bus and returns a Future. That would pull channels off the bus using rx::()?.
spawn_many would take a core size, and a max size. If the core size could not be fulfilled, the spawn would fail.
This is interesting. Multiple tasks will need to share a lifeline value.
If one of the inputs to Task::spawn was &Bus, lifeline could create and execute a group of message receivers, not just one.
Lifeline would take the bus, and a FnMut spawn function which receives &Bus and returns a Future. That would pull channels off the bus using rx::()?.
spawn_many would take a core size, and a max size. If the core size could not be fulfilled, the spawn would fail.