fleetctl: call cAPI.UnitStates() only once before checking unit states
fleetctl: call cAPI.UnitStates() only once before checking unit states

As it's basically not efficient to call cAPI.UnitStates() for each unit,
let's call it only once outside goroutines for processing units, i.e.
calling in waitForSystemdActiveState(), not in getSingleUnitState().
To do that, we need to share the result apiStates across all units.

Also make use of goroutines in waitForSystemdActiveState(), instead of
sequential iteration over each unit.

Note that we still need to keep calling UnitStates() when
assertSystemdActiveState() failed, because in the next attempt the old
apiState is not necessarily going to be valid. Ideally in that case, we
should be able to fetch the state only for a single unit. However, we
cannot do that for now, because cAPI.UnitState() is not available. In
the future we would need to implement cAPI.UnitState() and all
dependendent parts all over the tree in fleet, e.g. schema, etcdRegistry,
rpcRegistry, etc. to replace UnitStates() in this place with the new
method UnitState(). In practice, calling UnitStates() here is not as
badly inefficient as it looks, because it will be anyway rarely called
only when the assertion failed.

coreos/fleet,dongsupark/fleet,coreos/fleet,endocode/fleet,giantswarm/fleet,jonboulle/fleet,giantswarm/fleet,giantswarm/fleet,endocode/fleet,endocode/fleet,dalbani/fleet,coreos/fleet,jonboulle/fleet,dalbani/fleet,jonboulle/fleet,dalbani/fleet,dongsupark/fleet,dongsupark/fleet