Releases: travelaudience/go-nested
Releases · travelaudience/go-nested
v0.4.0
v0.3.1
Simplifies the registering of callback functions, fixing an issue where a non-comparable observer would cause a runtime panic when added to the observer map.
- Method
RegisterCallback
replacesRegister
. - Method
DeregisterCallback
replacesDeregister
. - Method
OnNotify
has been removed.
Full Changelog: v0.3.0...v0.3.1
v0.3.0
Changes to the basic design, including:
- New
Initializing
state. Not Ready
state renamed toError
.- Error values are now only applicable to the
Error
state. - State changes are now notified via callbacks.
- Collections now keep track of the error values of their monitored services.
- Collections now require a call to
Run()
to start monitoring. This is necessary in order to correctly report if any of the monitored services are initializing.
This release is not backwards-compatible.
v0.2.0
API Improvements:
- Renames
GetState()
toGetFullState()
. - Introduces a new
GetState()
that returns only the state value (without the error state), eliminating the need for theif s, _ := x.GetState(); s == nested.Ready {
pattern. - Adds a
label
parameter toCollection.Add()
, so that services in the collection can be referenced. - Adds the method
Collection.Up()
to return a map indicating the readiness of all currently monitored services.