Skip to content

v5.0.0

Compare
Choose a tag to compare
@xgfone xgfone released this 15 May 12:32
· 40 commits to master since this release
  • Added:
    • Add the method UnregisterOpts for OptGroup to unregister the registered options.
    • Add the method LoadDataSetCallback for Config to be used the watcher of the source.
  • Changed:
    • Set, UpdateValue and UpdateOptValue return an error if failing to update the option.
    • LoadMap, LoadDataSet, , return an error if failing to load the configurations.
    • RegisterOpts panics instead of returning the bool if the option has been registered.
    • Snapshot no longer contains the default values of the options.
    • Move the type XXXOptField to the sub-package field.
    • Change the signature of the method Watch of Source from
      Watch(load func(DataSet, error), close <-chan struct{})
      to
      Watch(load func(DataSet, error) bool, close <-chan struct{})
  • Removed:
    • Remove the field Callback from DataSet.
    • Remove the method RegisterOpt from OptGroup.
    • Remove the observer of the opt registering, that's ObserveRegister.
    • Remove the methods LoadSourceAndCallback and LoadSourceAndCallbackWithoutWatch from Config.