metric 등록 오류 수정
This commit is contained in:
@ -297,12 +297,11 @@ func (hc *houstonClient) launch(meta *procmeta) error {
|
|||||||
logger.Println("unmarshal metric failed :", err, string(metricBuffer))
|
logger.Println("unmarshal metric failed :", err, string(metricBuffer))
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
if index != 0 {
|
|
||||||
if desc.ConstLabels == nil {
|
if desc.ConstLabels == nil {
|
||||||
desc.ConstLabels = make(map[string]string)
|
desc.ConstLabels = make(map[string]string)
|
||||||
}
|
}
|
||||||
desc.ConstLabels["index"] = fmt.Sprintf("%d", index)
|
desc.ConstLabels["index"] = fmt.Sprintf("%d", index)
|
||||||
}
|
|
||||||
|
|
||||||
metricExporter.RegisterMetric(&desc)
|
metricExporter.RegisterMetric(&desc)
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
Reference in New Issue
Block a user