Code review comment for lp:~themue/juju-core/go-state-lifecycle-relation

Revision history for this message
Aram Hăvărneanu (aramh) wrote :

https://codereview.appspot.com/6455065/diff/11001/state/lifecycle.go
File state/lifecycle.go (right):

https://codereview.appspot.com/6455065/diff/11001/state/lifecycle.go#newcode96
state/lifecycle.go:96: value, found := config.Get(lifeKey)
Isn't there a race between config.Get() and config.{Set,Write}()?

https://codereview.appspot.com/6455065/diff/11001/state/lifecycle_test.go
File state/lifecycle_test.go (right):

https://codereview.appspot.com/6455065/diff/11001/state/lifecycle_test.go#newcode90
state/lifecycle_test.go:90: c.Assert(func() { lc.SetLife(test.panicLife)
}, PanicMatches, panicMessage)
Did not know about PanicMatches, thanks!

https://codereview.appspot.com/6455065/diff/11001/state/state.go
File state/state.go (right):

https://codereview.appspot.com/6455065/diff/11001/state/state.go#newcode419
state/state.go:419: return fmt.Errorf("cannot retrieve lifecacle state
of relation %q: %s", r, err)
s/lifecacle/lifecycle/

https://codereview.appspot.com/6455065/

« Back to merge proposal