A set of building blocks for instrumenting KrakenD gateways
There are the avaliable middlewares to add to the KrakenD pipes.
- Backend
- Proxy
- Router
Check the examples and the documentation for more details
You need to add an ExtraConfig section to the configuration to enable the metrics collector (an empty one will use the defaults).
You can disable metrics by layer by explicitly setting it to true (the default is to be enabled):
backend_disabled
boolproxy_disabled
boolrouter_disabled
bool
Or configure the collection time of metrics:
collection_time
(default: 60s) (Ex: "30s", "5m", "500ms", ...)
This configuration will set the collection time to 2 minutes and will disable the proxy metrics collector (backend and router metrics will be enabled since the default for all layers is to be enabled).
"extra_config": {
"github_com/devopsfaith/krakend-metrics": {
"collection_time": "2m",
"proxy_disabled": true,
}
}
or leave the defaults:
"extra_config": {
github_com/devopsfaith/krakend-metrics": {}
}