{
  "configurations": [
    {
      "declarative_name": "java.runtime_telemetry.emit_experimental_jfr_metrics/development",
      "default": false,
      "description": "Enables the capture of experimental JFR-based JVM runtime metrics on Java 17+.",
      "name": "otel.instrumentation.runtime-telemetry.emit-experimental-jfr-metrics",
      "type": "boolean"
    },
    {
      "declarative_name": "java.runtime_telemetry.emit_experimental_metrics/development",
      "default": false,
      "description": "Enables the capture of experimental JMX-based JVM runtime metrics.",
      "name": "otel.instrumentation.runtime-telemetry.emit-experimental-metrics",
      "type": "boolean"
    },
    {
      "declarative_name": "java.runtime_telemetry.package_emitter/development.enabled",
      "default": false,
      "description": "Enables creating events for JAR libraries used by the application.",
      "name": "otel.instrumentation.runtime-telemetry.experimental.package-emitter.enabled",
      "type": "boolean"
    },
    {
      "declarative_name": "java.runtime_telemetry.package_emitter/development.jars_per_second",
      "default": 10,
      "description": "The number of JAR files processed per second by the package emitter.",
      "name": "otel.instrumentation.runtime-telemetry.experimental.package-emitter.jars-per-second",
      "type": "int"
    },
    {
      "declarative_name": "java.runtime_telemetry.prefer_jfr/development",
      "default": false,
      "description": "Prefer JFR over JMX for metrics available from both sources, on Java 17+. When enabled, overlapping metrics are collected via JFR and the corresponding JMX metrics are suppressed.",
      "name": "otel.instrumentation.runtime-telemetry.experimental.prefer-jfr",
      "type": "boolean"
    }
  ],
  "description": "This instrumentation enables JVM runtime metrics using JMX (Java 8+) and JFR (Java 17+) to monitor classes, CPU, garbage collection, memory, and threads.",
  "display_name": "JVM Runtime Telemetry",
  "has_javaagent": true,
  "has_standalone_library": true,
  "library_link": "https://github.com/open-telemetry/opentelemetry-java-instrumentation/tree/main/instrumentation/runtime-telemetry",
  "markdown_hash": "74ae1ba34796",
  "name": "runtime-telemetry",
  "scope": {
    "name": "io.opentelemetry.runtime-telemetry"
  },
  "semantic_conventions": [
    "JVM_RUNTIME_METRICS"
  ],
  "source_path": "instrumentation/runtime-telemetry",
  "telemetry": [
    {
      "metrics": [
        {
          "attributes": [
            {
              "name": "jvm.buffer.pool.name",
              "type": "STRING"
            }
          ],
          "data_type": "LONG_SUM",
          "description": "Number of buffers in the pool.",
          "instrument": "updowncounter",
          "name": "jvm.buffer.count",
          "unit": "{buffer}"
        },
        {
          "attributes": [
            {
              "name": "jvm.buffer.pool.name",
              "type": "STRING"
            }
          ],
          "data_type": "LONG_SUM",
          "description": "Measure of total memory capacity of buffers.",
          "instrument": "updowncounter",
          "name": "jvm.buffer.memory.limit",
          "unit": "By"
        },
        {
          "attributes": [
            {
              "name": "jvm.buffer.pool.name",
              "type": "STRING"
            }
          ],
          "data_type": "LONG_SUM",
          "description": "Measure of memory used by buffers.",
          "instrument": "updowncounter",
          "name": "jvm.buffer.memory.used",
          "unit": "By"
        },
        {
          "attributes": [],
          "data_type": "LONG_SUM",
          "description": "Number of classes currently loaded.",
          "instrument": "updowncounter",
          "name": "jvm.class.count",
          "unit": "{class}"
        },
        {
          "attributes": [],
          "data_type": "LONG_SUM",
          "description": "Number of classes loaded since JVM start.",
          "instrument": "counter",
          "name": "jvm.class.loaded",
          "unit": "{class}"
        },
        {
          "attributes": [],
          "data_type": "LONG_SUM",
          "description": "Number of classes unloaded since JVM start.",
          "instrument": "counter",
          "name": "jvm.class.unloaded",
          "unit": "{class}"
        },
        {
          "attributes": [],
          "data_type": "LONG_SUM",
          "description": "Number of processors available to the Java virtual machine.",
          "instrument": "updowncounter",
          "name": "jvm.cpu.count",
          "unit": "{cpu}"
        },
        {
          "attributes": [],
          "data_type": "HISTOGRAM",
          "description": "Long lock times",
          "instrument": "histogram",
          "name": "jvm.cpu.longlock",
          "unit": "s"
        },
        {
          "attributes": [],
          "data_type": "DOUBLE_GAUGE",
          "description": "Recent CPU utilization for the process as reported by the JVM.",
          "instrument": "gauge",
          "name": "jvm.cpu.recent_utilization",
          "unit": "1"
        },
        {
          "attributes": [],
          "data_type": "DOUBLE_SUM",
          "description": "CPU time used by the process as reported by the JVM.",
          "instrument": "counter",
          "name": "jvm.cpu.time",
          "unit": "s"
        },
        {
          "attributes": [
            {
              "name": "jvm.gc.action",
              "type": "STRING"
            },
            {
              "name": "jvm.gc.name",
              "type": "STRING"
            }
          ],
          "data_type": "HISTOGRAM",
          "description": "Duration of JVM garbage collection actions.",
          "instrument": "histogram",
          "name": "jvm.gc.duration",
          "unit": "s"
        },
        {
          "attributes": [
            {
              "name": "jvm.memory.pool.name",
              "type": "STRING"
            },
            {
              "name": "jvm.memory.type",
              "type": "STRING"
            }
          ],
          "data_type": "LONG_SUM",
          "description": "Measure of memory committed.",
          "instrument": "updowncounter",
          "name": "jvm.memory.committed",
          "unit": "By"
        },
        {
          "attributes": [
            {
              "name": "jvm.memory.pool.name",
              "type": "STRING"
            },
            {
              "name": "jvm.memory.type",
              "type": "STRING"
            }
          ],
          "data_type": "LONG_SUM",
          "description": "Measure of initial memory requested.",
          "instrument": "updowncounter",
          "name": "jvm.memory.init",
          "unit": "By"
        },
        {
          "attributes": [
            {
              "name": "jvm.memory.pool.name",
              "type": "STRING"
            },
            {
              "name": "jvm.memory.type",
              "type": "STRING"
            }
          ],
          "data_type": "LONG_SUM",
          "description": "Measure of max obtainable memory.",
          "instrument": "updowncounter",
          "name": "jvm.memory.limit",
          "unit": "By"
        },
        {
          "attributes": [
            {
              "name": "jvm.memory.pool.name",
              "type": "STRING"
            },
            {
              "name": "jvm.memory.type",
              "type": "STRING"
            }
          ],
          "data_type": "LONG_SUM",
          "description": "Measure of memory used.",
          "instrument": "updowncounter",
          "name": "jvm.memory.used",
          "unit": "By"
        },
        {
          "attributes": [
            {
              "name": "jvm.memory.pool.name",
              "type": "STRING"
            },
            {
              "name": "jvm.memory.type",
              "type": "STRING"
            }
          ],
          "data_type": "LONG_SUM",
          "description": "Measure of memory used, as measured after the most recent garbage collection event on this pool.",
          "instrument": "updowncounter",
          "name": "jvm.memory.used_after_last_gc",
          "unit": "By"
        },
        {
          "attributes": [],
          "data_type": "DOUBLE_GAUGE",
          "description": "Recent CPU utilization for the whole system as reported by the JVM.",
          "instrument": "gauge",
          "name": "jvm.system.cpu.utilization",
          "unit": "1"
        },
        {
          "attributes": [
            {
              "name": "jvm.thread.daemon",
              "type": "BOOLEAN"
            },
            {
              "name": "jvm.thread.state",
              "type": "STRING"
            }
          ],
          "data_type": "LONG_SUM",
          "description": "Number of executing platform threads.",
          "instrument": "updowncounter",
          "name": "jvm.thread.count",
          "unit": "{thread}"
        }
      ],
      "when": "Java17"
    },
    {
      "metrics": [
        {
          "attributes": [],
          "data_type": "LONG_SUM",
          "description": "Number of classes currently loaded.",
          "instrument": "updowncounter",
          "name": "jvm.class.count",
          "unit": "{class}"
        },
        {
          "attributes": [],
          "data_type": "LONG_SUM",
          "description": "Number of classes loaded since JVM start.",
          "instrument": "counter",
          "name": "jvm.class.loaded",
          "unit": "{class}"
        },
        {
          "attributes": [],
          "data_type": "LONG_SUM",
          "description": "Number of classes unloaded since JVM start.",
          "instrument": "counter",
          "name": "jvm.class.unloaded",
          "unit": "{class}"
        },
        {
          "attributes": [],
          "data_type": "LONG_SUM",
          "description": "Number of processors available to the Java virtual machine.",
          "instrument": "updowncounter",
          "name": "jvm.cpu.count",
          "unit": "{cpu}"
        },
        {
          "attributes": [],
          "data_type": "DOUBLE_GAUGE",
          "description": "Recent CPU utilization for the process as reported by the JVM.",
          "instrument": "gauge",
          "name": "jvm.cpu.recent_utilization",
          "unit": "1"
        },
        {
          "attributes": [],
          "data_type": "DOUBLE_SUM",
          "description": "CPU time used by the process as reported by the JVM.",
          "instrument": "counter",
          "name": "jvm.cpu.time",
          "unit": "s"
        },
        {
          "attributes": [
            {
              "name": "jvm.memory.pool.name",
              "type": "STRING"
            },
            {
              "name": "jvm.memory.type",
              "type": "STRING"
            }
          ],
          "data_type": "LONG_SUM",
          "description": "Measure of memory committed.",
          "instrument": "updowncounter",
          "name": "jvm.memory.committed",
          "unit": "By"
        },
        {
          "attributes": [
            {
              "name": "jvm.memory.pool.name",
              "type": "STRING"
            },
            {
              "name": "jvm.memory.type",
              "type": "STRING"
            }
          ],
          "data_type": "LONG_SUM",
          "description": "Measure of max obtainable memory.",
          "instrument": "updowncounter",
          "name": "jvm.memory.limit",
          "unit": "By"
        },
        {
          "attributes": [
            {
              "name": "jvm.memory.pool.name",
              "type": "STRING"
            },
            {
              "name": "jvm.memory.type",
              "type": "STRING"
            }
          ],
          "data_type": "LONG_SUM",
          "description": "Measure of memory used.",
          "instrument": "updowncounter",
          "name": "jvm.memory.used",
          "unit": "By"
        },
        {
          "attributes": [
            {
              "name": "jvm.memory.pool.name",
              "type": "STRING"
            },
            {
              "name": "jvm.memory.type",
              "type": "STRING"
            }
          ],
          "data_type": "LONG_SUM",
          "description": "Measure of memory used, as measured after the most recent garbage collection event on this pool.",
          "instrument": "updowncounter",
          "name": "jvm.memory.used_after_last_gc",
          "unit": "By"
        },
        {
          "attributes": [
            {
              "name": "jvm.thread.daemon",
              "type": "BOOLEAN"
            },
            {
              "name": "jvm.thread.state",
              "type": "STRING"
            }
          ],
          "data_type": "LONG_SUM",
          "description": "Number of executing platform threads.",
          "instrument": "updowncounter",
          "name": "jvm.thread.count",
          "unit": "{thread}"
        },
        {
          "attributes": [],
          "data_type": "HISTOGRAM",
          "description": "Duration of virtual thread pinning.",
          "instrument": "histogram",
          "name": "jvm.thread.virtual.pinned",
          "unit": "s"
        }
      ],
      "when": "Java21"
    },
    {
      "metrics": [
        {
          "attributes": [
            {
              "name": "jvm.buffer.pool.name",
              "type": "STRING"
            }
          ],
          "data_type": "LONG_SUM",
          "description": "Number of buffers in the pool.",
          "instrument": "updowncounter",
          "name": "jvm.buffer.count",
          "unit": "{buffer}"
        },
        {
          "attributes": [
            {
              "name": "jvm.buffer.pool.name",
              "type": "STRING"
            }
          ],
          "data_type": "LONG_SUM",
          "description": "Measure of total memory capacity of buffers.",
          "instrument": "updowncounter",
          "name": "jvm.buffer.memory.limit",
          "unit": "By"
        },
        {
          "attributes": [
            {
              "name": "jvm.buffer.pool.name",
              "type": "STRING"
            }
          ],
          "data_type": "LONG_SUM",
          "description": "Measure of memory used by buffers.",
          "instrument": "updowncounter",
          "name": "jvm.buffer.memory.used",
          "unit": "By"
        },
        {
          "attributes": [],
          "data_type": "LONG_SUM",
          "description": "Number of classes currently loaded.",
          "instrument": "updowncounter",
          "name": "jvm.class.count",
          "unit": "{class}"
        },
        {
          "attributes": [],
          "data_type": "LONG_SUM",
          "description": "Number of classes loaded since JVM start.",
          "instrument": "counter",
          "name": "jvm.class.loaded",
          "unit": "{class}"
        },
        {
          "attributes": [],
          "data_type": "LONG_SUM",
          "description": "Number of classes unloaded since JVM start.",
          "instrument": "counter",
          "name": "jvm.class.unloaded",
          "unit": "{class}"
        },
        {
          "attributes": [],
          "data_type": "LONG_SUM",
          "description": "Number of processors available to the Java virtual machine.",
          "instrument": "updowncounter",
          "name": "jvm.cpu.count",
          "unit": "{cpu}"
        },
        {
          "attributes": [],
          "data_type": "DOUBLE_GAUGE",
          "description": "Recent CPU utilization for the process as reported by the JVM.",
          "instrument": "gauge",
          "name": "jvm.cpu.recent_utilization",
          "unit": "1"
        },
        {
          "attributes": [],
          "data_type": "DOUBLE_SUM",
          "description": "CPU time used by the process as reported by the JVM.",
          "instrument": "counter",
          "name": "jvm.cpu.time",
          "unit": "s"
        },
        {
          "attributes": [],
          "data_type": "LONG_SUM",
          "description": "Number of open file descriptors as reported by the JVM.",
          "instrument": "updowncounter",
          "name": "jvm.file_descriptor.count",
          "unit": "{file_descriptor}"
        },
        {
          "attributes": [],
          "data_type": "LONG_SUM",
          "description": "Measure of max open file descriptors as reported by the JVM.",
          "instrument": "updowncounter",
          "name": "jvm.file_descriptor.limit",
          "unit": "{file_descriptor}"
        },
        {
          "attributes": [
            {
              "name": "jvm.gc.action",
              "type": "STRING"
            },
            {
              "name": "jvm.gc.cause",
              "type": "STRING"
            },
            {
              "name": "jvm.gc.name",
              "type": "STRING"
            }
          ],
          "data_type": "HISTOGRAM",
          "description": "Duration of JVM garbage collection actions.",
          "instrument": "histogram",
          "name": "jvm.gc.duration",
          "unit": "s"
        },
        {
          "attributes": [
            {
              "name": "jvm.memory.pool.name",
              "type": "STRING"
            },
            {
              "name": "jvm.memory.type",
              "type": "STRING"
            }
          ],
          "data_type": "LONG_SUM",
          "description": "Measure of memory committed.",
          "instrument": "updowncounter",
          "name": "jvm.memory.committed",
          "unit": "By"
        },
        {
          "attributes": [
            {
              "name": "jvm.memory.pool.name",
              "type": "STRING"
            },
            {
              "name": "jvm.memory.type",
              "type": "STRING"
            }
          ],
          "data_type": "LONG_SUM",
          "description": "Measure of initial memory requested.",
          "instrument": "updowncounter",
          "name": "jvm.memory.init",
          "unit": "By"
        },
        {
          "attributes": [
            {
              "name": "jvm.memory.pool.name",
              "type": "STRING"
            },
            {
              "name": "jvm.memory.type",
              "type": "STRING"
            }
          ],
          "data_type": "LONG_SUM",
          "description": "Measure of max obtainable memory.",
          "instrument": "updowncounter",
          "name": "jvm.memory.limit",
          "unit": "By"
        },
        {
          "attributes": [
            {
              "name": "jvm.memory.pool.name",
              "type": "STRING"
            },
            {
              "name": "jvm.memory.type",
              "type": "STRING"
            }
          ],
          "data_type": "LONG_SUM",
          "description": "Measure of memory used.",
          "instrument": "updowncounter",
          "name": "jvm.memory.used",
          "unit": "By"
        },
        {
          "attributes": [
            {
              "name": "jvm.memory.pool.name",
              "type": "STRING"
            },
            {
              "name": "jvm.memory.type",
              "type": "STRING"
            }
          ],
          "data_type": "LONG_SUM",
          "description": "Measure of memory used, as measured after the most recent garbage collection event on this pool.",
          "instrument": "updowncounter",
          "name": "jvm.memory.used_after_last_gc",
          "unit": "By"
        },
        {
          "attributes": [],
          "data_type": "DOUBLE_GAUGE",
          "description": "Average CPU load of the whole system for the last minute as reported by the JVM.",
          "instrument": "gauge",
          "name": "jvm.system.cpu.load_1m",
          "unit": "{run_queue_item}"
        },
        {
          "attributes": [],
          "data_type": "DOUBLE_GAUGE",
          "description": "Recent CPU utilization for the whole system as reported by the JVM.",
          "instrument": "gauge",
          "name": "jvm.system.cpu.utilization",
          "unit": "1"
        },
        {
          "attributes": [
            {
              "name": "jvm.thread.daemon",
              "type": "BOOLEAN"
            },
            {
              "name": "jvm.thread.state",
              "type": "STRING"
            }
          ],
          "data_type": "LONG_SUM",
          "description": "Number of executing platform threads.",
          "instrument": "updowncounter",
          "name": "jvm.thread.count",
          "unit": "{thread}"
        }
      ],
      "when": "default"
    }
  ]
}