deploykit
deploykit copied to clipboard
Group updater: add support for parallelism
Addresses this TODO in rollingupdate.go
:
// TODO(wfarner): Make the 'batch size' configurable.
We should accept a parallelism
flag for updates to allow multiple instances to be drained simultaneously.
I wonder where this will go. Is this a responsibility of Flavor or the group? I would think the Flavor worries about how to do a drain, and Group worries about how many at a time -- assuming different instances can be drained in parallel.
It's the inverse of the instance's Provision
. So in the sense that a Flavor's Prepare
is chained to the Instance's Provision
, a Flavor's Drain
should be chained to the Instance's Destroy
.
Related #235
Flavor's Drain should be chained to the Instance's Destroy
That's exactly what i was thinking.
There are some use cases that we should anticipate (but probably not solve yet) - where parallelism should be selective. For example, in a Swarm we would ideally not pick all N instances hosting a particular service.