|
|
@@ -66,14 +66,14 @@ func main() { |
|
|
|
fieldKeys := []string{"method"} |
|
|
|
requestCount := kitprometheus.NewCounterFrom(stdprometheus.CounterOpts{ |
|
|
|
Namespace: config.Cfg.Get("name").(string), |
|
|
|
Subsystem: "job_risk_third_service", |
|
|
|
Subsystem: config.Cfg.Get("name").(string) + "_service", |
|
|
|
Name: "request_count", |
|
|
|
Help: "收到的请求数", |
|
|
|
}, fieldKeys) |
|
|
|
|
|
|
|
requestLatency := kitprometheus.NewSummaryFrom(stdprometheus.SummaryOpts{ |
|
|
|
Namespace: config.Cfg.Get("name").(string), |
|
|
|
Subsystem: "job_risk_third_service", |
|
|
|
Subsystem: config.Cfg.Get("name").(string) + "_service", |
|
|
|
Name: "request_latency", |
|
|
|
Help: "请求的总持续时间(以微秒为单位)", |
|
|
|
}, fieldKeys) |
|
|
@@ -82,7 +82,7 @@ func main() { |
|
|
|
var ( |
|
|
|
err error |
|
|
|
hostPort = fmt.Sprintf("%s:%d", zipkinConf.Address, zipkinConf.Port) |
|
|
|
serviceName = "insigma_service" |
|
|
|
serviceName = config.Cfg.Get("name").(string) + "_service" |
|
|
|
useNoopTracer = zipkinConf.ZipkinURL == "" |
|
|
|
reporters = zipkinhttp.NewReporter(zipkinConf.ZipkinURL) |
|
|
|
) |
|
|
|