dixingxing0 opened a new issue #6382:
URL: https://github.com/apache/incubator-doris/issues/6382


   Currently FE's metrics API (http://fe_host:fe_port/metrics) return metrics 
like this:
   
   ```
   ...
   # HELP doris_fe_job job statistics
   # TYPE doris_fe_job gauge
   doris_fe_job{job="load", type="HADOOP", state="UNKNOWN"} 0
   # HELP doris_fe_job job statistics
   # TYPE doris_fe_job gauge
   doris_fe_job{job="load", type="HADOOP", state="PENDING"} 0
   # HELP doris_fe_job job statistics
   # TYPE doris_fe_job gauge
   doris_fe_job{job="load", type="HADOOP", state="ETL"} 0
   ...
   ```
   And we encountered an exception when using prometheus's 
[text-parser](https://github.com/prometheus/common/blob/8d1c9f84e3f78cb628a20f8e7be531c508237848/expfmt/text_parse.go#L496)
 to parse the metrics text:
   
   ```
   text format parsing error in line 40: second HELP line for metric name 
"doris_fe_job"
   ```
   I think doris should follow the format definition of prometheus and return 
metrics like this:
   
   ```
   ...
   # HELP doris_fe_job job statistics
   # TYPE doris_fe_job gauge
   doris_fe_job{job="load", type="HADOOP", state="UNKNOWN"} 0
   doris_fe_job{job="load", type="HADOOP", state="PENDING"} 0
   doris_fe_job{job="load", type="HADOOP", state="ETL"} 0
   ...
   ```
   
   I'll try to submit a PR to improve it.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to