metric namespace 설정 추가

This commit is contained in:
2023-11-26 18:02:02 +09:00
parent 72b88b194f
commit cf4b458a4b
2 changed files with 2 additions and 2 deletions

View File

@ -34,7 +34,7 @@ type clientConfig struct {
GrpcAddress string `json:"grpc_server_address"`
HttpAddress string `json:"http_server_address"`
StorageRoot string `json:"storage_path"`
RunNodeExporter bool `json:"run_node_exporter"`
MetricNamespace string `json:"metric_namespace"`
}
func loadClientConfig() (clientConfig, error) {

View File

@ -275,7 +275,7 @@ func (hc *houstonClient) launch(meta *procmeta) error {
if _, registered := metricValues[metric.Key]; !registered {
exporter := newExporterForPrometheus()
accessor := exporter.registMetric(childProcName, metric)
accessor := exporter.registMetric(hc.config.MetricNamespace, metric)
prometheus.Register(exporter)