chenxingwei-wayne commented on a change in pull request #113: [SCB-1470] adjust 
content position of metrics doc
URL: https://github.com/apache/servicecomb-docs/pull/113#discussion_r369948261
 
 

 ##########
 File path: java-chassis-reference/en_US/general-development/metrics.md
 ##########
 @@ -10,7 +10,177 @@
   3. Publisher: Output statistics, built-in log output, and output via RESTful 
interface
   4. Metrics-prometheus provides the ability to interface with prometheus
 
-# Second, the summary of statistical items
+# Second, how to use.
+
+### 1.Maven dependence.
+
+```
+<dependency>
+  <groupId>org.apache.servicecomb</groupId>
+  <artifactId>metrics-core</artifactId>
+  <version>1.2.0</version>
+</dependency>
+```
+If integrate with prometheus, also need to add dependencies.
+```
+<dependency>
+  <groupId>org.apache.servicecomb</groupId>
+  <artifactId>metrics-prometheus</artifactId>
+  <version>1.2.0</version>
+</dependency>
+```
+
+_Note: Please change the version field to the actual version number; if the 
version number has been declared in the dependencyManagement, then you do not 
have to write the version number here_
+
+### 2. Configuration instructions
+
+<div class="metrics-cfg"></div>
+
+| Configuration Item | Default | Meaning |
+| :--- | :--- | :--- |
+| servicecomb.metrics.window_time | 60000 | Statistical period, in 
milliseconds<br>TPS, delay, etc. Periodic data, updated once per cycle, the 
value obtained in the cycle, actually the value of the previous cycle |
+| servicecomb.metrics<br>.invocation.latencyDistribution |       | The latency 
distribution time period definition in milliseconds<br>for 
example:0,1,10,100,1000<br>indicates that the following latency scopes are 
defined: [0, 1),[1, 10),[10, 100),[100, 1000),[1000, ) |
+| servicecomb.metrics<br>.Consumer.invocation.slow.enabled | false | Whether 
to enable slow call detection on the Consumer side<br>Level 4 priority 
definitions can be supported by adding the suffix 
.${service}.${schema}.${operation} |
+| servicecomb.metrics<br>.Consumer.invocation.slow.msTime | 1000 | If the 
latency exceeds the configured value, the log will be output immediately, and 
the time consumption information of the stage called this time will be 
recorded.<br>Level 4 priority definitions can be supported by adding the suffix 
.${service}.${schema}.${operation} |
+| servicecomb.metrics<br>.Provider.invocation.slow.enabled | false | Whether 
to enable slow call detection on the Provider side<br>Level 4 priority 
definitions can be supported by adding the suffix 
.${service}.${schema}.${operation} |
+| servicecomb.metrics<br>.Provider.invocation.slow.msTime | 1000 | If the 
latency exceeds the configured value, the log will be output immediately, and 
the time consumption information of the stage called this time will be 
recorded.<br>Level 4 priority definitions can be supported by adding the suffix 
.${service}.${schema}.${operation} |
+| servicecomb.metrics<br>.prometheus.address | 0.0.0.0:9696 | prometheus 
listen address |
+| servicecomb.metrics.publisher.defaultLog<br>.enabled | false | Whether to 
output the default statistics log |
+| servicecomb.metrics.publisher.defaultLog<br>.endpoints.client.detail.enabled 
| false | Whether to output each client endpoint statistics log, because it is 
related to the target ip:port number, there may be a lot of data, so the 
default is not output|
+  
+### 3.慢调用检测
 
 Review comment:
   Has removed now, please help review.

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to