A service for configuration management in distributed system.
key could indicate a configuration like “timeout”, then the value could be “3s” or indicates a file name “app.properties”, then the value could be content of app.properties
Each key could has labels. labels indicates a unique key. A key “log_level” with labels “env=production” may saves the value “INFO” for all application log level in production environment. A key “log_level” with labels “env=production, component=payment” may saves the value “DEBUG” for payment service in production environment.
it means all payment service print debug log, but for other service print info log.
so you can control your application runtime behaviors by setting different labels to a key.
it includes 5 components
- server: rest api service to manage kv
- client: restful client for go
- kie-template: agent can be deployed in your k8s pod or VM, it connects to server and writes kv into config file based on template language
- kiectl: CLI tool for kie
- frontend: web console for kie
- simple key name with rich labels: user can define labels for a key, that distinguish from key to another key.
- a key will not be stringed by fixed schema. labels for a key is like “env=test, service=cart, version=1.0” or “cluster=xxx”
or “env=test, service=cart, version=1.0, ip=x.x.x.x”
- validator: value can be checked by user defined python script, so in runtime if someone want to change this value, the script will check if this value is appropriate.
- encryption web hook: value can by encrypt by your custom encryption service like vault.
- Long polling: client can get key value changes by long polling
- config view: by setting labels criteria, servicecomb-kie is able to aggregate a view to return all key values which match those labels, so that operator can mange key in their own understanding to a distributed system in separated views.
- rich value type: not only plain text, but support to be aware of ini, json,yaml,xml and java properties
- heterogeneous config server: able to fetch configuration in k8s and consul even more, you can update, delete, and use config view for those systems, and you can integrate with your own config system to MetaConfig by following standardized API and model
- consul compatible: partially compatible with consul kv management API
- kv change history: all kv changes is recorded and can be easily roll back by UI
Run locally with Docker compose
git clone email@example.com:apache/servicecomb-kie.git
sudo docker-compose up
it will launch 3 components
To see how to build a local dev environment, check here
this will build your own service image and binary in local
export VERSION=0.0.1 #optional, it is latest by default
this will generate a “servicecomb-kie-0.0.1-linux-amd64.tar” in “release” folder, and a docker image “servicecomb/kie:0.0.1”
After you launch kie server, you can browse API doc in http://127.0.0.1:30110/apidocs, copy this doc to http://editor.swagger.io/
or follow here to generate it in local
See Contribution guide for details on submitting patches and the contribution workflow.
See reporting bugs for details about reporting any issues.