blob: 799ba2d2a30eaead63c167dff33c61ed7ce4bf72 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
|
package metrics
import "github.com/spiral/roadrunner/service"
type Config struct {
// Address to listen
Address string
// Metrics define application specific metrics.
Metrics map[string]Metric
}
// Metric describes single application specific metric.
type Metric struct {
Type string
Description string
Labels []string
}
// Hydrate configuration.
func (c *Config) Hydrate(cfg service.Config) error {
return cfg.Unmarshal(c)
}
|