Descriptionstate: add allWatcher
This is the data structure that will manage the
shared state for all watching clients.
Initially, we have a single method, "change", which
mutates the state in response to a watcher-for change.
For the record, this is the allWatcher inner loop as planned:
for {
select {
case <-aw.tomb.Dying():
return tomb.ErrDying
case change := <-in:
if err := aw.changed(change); err != nil {
return err
}
case req := <-aw.request:
aw.handle(req)
}
aw.respond()
}
https://code.launchpad.net/~rogpeppe/juju-core/241-allwatcher-changed/+merge/153203
(do not edit description out of merge proposal)
Patch Set 1 #Patch Set 2 : state: add allWatcher #Patch Set 3 : state: add allWatcher #Patch Set 4 : state: add allWatcher #Patch Set 5 : state: add allWatcher #
Total comments: 2
Patch Set 6 : state: add allWatcher #
MessagesTotal messages: 5
|