【问题标题】:Where can I find descriptions of Spring Boot metrics?在哪里可以找到 Spring Boot 指标的描述?
【发布时间】:2019-12-04 08:21:14
【问题描述】:

我们有一个 Spring Boot (1.5.3) 应用程序,它使用 Micrometer.io 和 InfluxDB 收集指标并使用 Grafana 显示它们。

当我查看 InfluxDB 记录时,我可以看到它包含以下指标的值:

dataSource_connections_active
dataSource_connections_max
dataSource_connections_min
jvm_buffer_count
jvm_buffer_memory_used
jvm_buffer_total_capacity
jvm_classes_loaded
jvm_classes_unloaded
jvm_gc_live_data_size
jvm_gc_max_data_size
jvm_gc_memory_allocated
jvm_gc_memory_promoted
jvm_gc_pause
jvm_memory_committed
jvm_memory_max
jvm_memory_used
jvm_threads_daemon
jvm_threads_live
jvm_threads_peak
jvm_threads_states
logback_events
process_cpu_usage
process_files_max
process_files_open
process_start_time
process_uptime
request_duration
system_cpu_count
system_cpu_usage
system_load_average_1m
tomcat_global_error
tomcat_global_received
tomcat_global_request
tomcat_global_request_max
tomcat_global_sent
tomcat_sessions_active_current
tomcat_sessions_active_max
tomcat_sessions_alive_max
tomcat_sessions_created
tomcat_sessions_expired
tomcat_sessions_rejected
tomcat_threads_busy
tomcat_threads_config_max
tomcat_threads_current

我不确定这些是 Sprint Boot 指标还是包含一些 Micrometer 魔法,但无论哪种情况,我都无法找到这些指标的详细描述,尤其是内存和 GC 相关的指标。

jvm_gc_live_data_size
jvm_gc_max_data_size
jvm_gc_memory_allocated
jvm_gc_memory_promoted
jvm_gc_pause
jvm_memory_committed
jvm_memory_max
jvm_memory_used

不知何故,Sprint Boot 文档没有提供详细信息,Micrometer 文档也没有。

谁能指出我可以找到这些指标的详细解释的地方?

【问题讨论】:

    标签: java spring-boot jvm monitoring metrics


    【解决方案1】:

    您可以在千分尺源代码中找到这些指标的定义:https://github.com/micrometer-metrics/micrometer,以及它们的名称、描述和基本单位。

    例如,jvm_memory_max 在这里定义:https://github.com/micrometer-metrics/micrometer/blob/48eb59d3b5cb5e4df7f35c0dfa323241f3cf2484/micrometer-core/src/main/java/io/micrometer/core/instrument/binder/jvm/JvmMemoryMetrics.java#L97

    所以 jvm_memory_max 是“可用于内存管理的最大内存量(以字节为单位)”。

    【讨论】:

    猜你喜欢
    • 2019-12-16
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2022-01-14
    • 2023-03-28
    • 2022-10-17
    相关资源
    最近更新 更多