Comment 1 for bug 809599

Revision history for this message
Clint Byrum (clint-fewbar) wrote : Re: [Bug 809599] [NEW] ensemble add-unit should support adding more than one unit at a time

Excerpts from Jim Baker's message of Tue Jul 12 22:16:30 UTC 2011:
> Public bug reported:
>
> Seeing blogs with info like the following suggests that add-unit should
> take an optional parameter (maybe -n and --num-units, there may be
> better options) to describe the number of units to add:
>
> ensemble add-unit hadoop-slave
> ensemble add-unit hadoop-slave
> ensemble add-unit hadoop-slave
> ensemble add-unit hadoop-slave

I'd like it to go even further and also have the idea of sizing services:

ensemble deploy formula-bar srv-foo --size 5

or resizing:

ensemble resize-service srv-foo #

Where it will tell me

srv-foo has 5 units
Desired size is 3
Terminated units:
  srv-foo/8
    machine: 12: { dns_name: ec2-xxxxxxx }
  srv-foo/9
    machine: 17: { dns_name: ec2-xxxxxxx }

Or if expanding:

srv-foo has 3 units
Desired size is 5:
Allocating existing machines:
  machine: 19 { dns_name: ec2-xxxxxxx}
Provisioning 1 new machine(s)

It should probably default to confirming this without a --yes/-y flag
to avoid destroying data in something like Cassandra or Mongo.

Maybe this belongs in a separate feature request but I think its related.