mirror of
https://github.com/elyby/chrly.git
synced 2024-11-30 02:32:19 +05:30
Доработана конфигурация взаимодействия со statsd
This commit is contained in:
parent
201a257d69
commit
6a881a62e3
@ -63,11 +63,12 @@ func main() {
|
|||||||
// statsd
|
// statsd
|
||||||
var statsdString = os.Getenv("STATSD_ADDR")
|
var statsdString = os.Getenv("STATSD_ADDR")
|
||||||
if (statsdString != "") {
|
if (statsdString != "") {
|
||||||
|
log.Println("Connecting to statsd")
|
||||||
hostname, _ := os.Hostname()
|
hostname, _ := os.Hostname()
|
||||||
statsdReceiver, err := statsd.NewReceiver(statsd.Config{
|
statsdReceiver, err := statsd.NewReceiver(statsd.Config{
|
||||||
Address: statsdString,
|
Address: statsdString,
|
||||||
Prefix: "ely.skinsystem." + hostname + ".",
|
Prefix: "ely.skinsystem." + hostname + ".app.",
|
||||||
FlushEvery: 2,
|
FlushEvery: 1,
|
||||||
})
|
})
|
||||||
if (err != nil) {
|
if (err != nil) {
|
||||||
log.Fatal("statsd connection error")
|
log.Fatal("statsd connection error")
|
||||||
|
Loading…
Reference in New Issue
Block a user