1
0
mirror of https://github.com/go-micro/go-micro.git synced 2024-11-24 08:02:32 +02:00
go-micro/config
Christian Richter 7392705af8
bump urfave cli & fix race condition (#2659)
* bump urfave cli

Signed-off-by: Christian Richter <crichter@owncloud.com>

* Fix race condition

Co-authored-by: André Duffeck <andre.duffeck@firondu.de>

Signed-off-by: Christian Richter <crichter@owncloud.com>

---------

Signed-off-by: Christian Richter <crichter@owncloud.com>
2023-10-09 10:33:57 +01:00
..
encoder go-micro.dev/v4 (#2305) 2021-10-12 12:55:53 +01:00
loader bump urfave cli & fix race condition (#2659) 2023-10-09 10:33:57 +01:00
reader fix: some linting issues (#2563) 2022-09-30 16:27:07 +02:00
secrets fix: struct field alignment (#2632) 2023-04-26 02:16:34 +02:00
source fix(config/source/cli): mergo.Map error, src and dst must be of same … (#2628) 2023-04-26 02:21:08 +02:00
config.go fix: struct field alignment (#2632) 2023-04-26 02:16:34 +02:00
default_test.go go-micro.dev/v4 (#2305) 2021-10-12 12:55:53 +01:00
default.go bump urfave cli & fix race condition (#2659) 2023-10-09 10:33:57 +01:00
options.go fix: some linting issues (#2563) 2022-09-30 16:27:07 +02:00
README.md fix: linting issues (#2566) 2022-09-30 20:32:55 +02:00
value.go go-micro.dev/v4 (#2305) 2021-10-12 12:55:53 +01:00

Config GoDoc

Config is a pluggable dynamic config package

Most config in applications are statically configured or include complex logic to load from multiple sources. Go Config makes this easy, pluggable and mergeable. You'll never have to deal with config in the same way again.

Features

  • Dynamic Loading - Load configuration from multiple source as and when needed. Go Config manages watching config sources in the background and automatically merges and updates an in memory view.

  • Pluggable Sources - Choose from any number of sources to load and merge config. The backend source is abstracted away into a standard format consumed internally and decoded via encoders. Sources can be env vars, flags, file, etcd, k8s configmap, etc.

  • Mergeable Config - If you specify multiple sources of config, regardless of format, they will be merged and presented in a single view. This massively simplifies priority order loading and changes based on environment.

  • Observe Changes - Optionally watch the config for changes to specific values. Hot reload your app using Go Config's watcher. You don't have to handle ad-hoc hup reloading or whatever else, just keep reading the config and watch for changes if you need to be notified.

  • Sane Defaults - In case config loads badly or is completely wiped away for some unknown reason, you can specify fallback values when accessing any config values directly. This ensures you'll always be reading some sane default in the event of a problem.