diff --git a/instrumentation/jmx-metrics/javaagent/camel.md b/instrumentation/jmx-metrics/javaagent/camel.md index 724fb488aa2c..60cab476d2e4 100644 --- a/instrumentation/jmx-metrics/javaagent/camel.md +++ b/instrumentation/jmx-metrics/javaagent/camel.md @@ -2,50 +2,53 @@ Here is the list of metrics based on MBeans exposed by Camel. -| Metric Name | Type | Attributes | Description | -|------------------------------------------------|---------------|----------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| -| camel.context.exchange | Counter | context, camelVersion | Indicates the total number of exchanges, passed or failed, processed since context start-up or the last reset operation. | -| camel.context.exchange.completed | Counter | context, camelVersion | Indicates the total number of exchanges processed successfully since context start-up or the last reset operation. | -| camel.context.exchange.failed | Counter | context, camelVersion | Indicates the total number of exchanges that failed to process since context start-up or the last reset operation. | -| camel.context.exchange.failed_handled | Counter | context, camelVersion | Indicates the number of exchanges failed and handled by an ExceptionHandler in the context. | -| camel.context.exchange.inflight | UpDownCounter | context, camelVersion | Indicates the number of exchanges currently transiting the context. | -| camel.context.exchange.processing.delta_time | Gauge | context, camelVersion | Indicates the difference, in milliseconds, of the Processing Time of the last two exchanges transited the context. | -| camel.context.exchange.processing.last_time | Gauge | context, camelVersion | Indicates the time, in milliseconds, it took to process the last exchange. | -| camel.context.exchange.processing.max_time | Gauge | context, camelVersion | Indicates the longest time, in milliseconds, to process an exchange since context start-up or the last reset operation. | -| camel.context.exchange.processing.mean_time | Gauge | context, camelVersion | Indicates the mean processing time, in milliseconds, for all exchanges processed since context start-up or the last reset operation. | -| camel.context.exchange.processing.min_time | Gauge | context, camelVersion | Indicates the shortest time, in milliseconds, to process an exchange since context start-up or the last reset operation. | -| camel.context.exchange.processing.time | Counter | context, camelVersion | Indicates the total processing time, in milliseconds, to process all exchanges since context start-up or the last reset operation. | -| camel.context.exchange.redelivered | Counter | context, camelVersion | Number of exchanges redelivered (internal only) since context start-up or the last reset operation. | -| camel.context.exchange.redelivered_external | Counter | context, camelVersion | The total number of all external initiated redeliveries (such as from JMS broker) since context start-up or the last reset operation. | -| camel.route.exchange | Counter | context, route | Indicates the total number of exchanges, passed or failed, that the route has processed since route start-up or the last reset operation. | -| camel.route.exchange.completed | Counter | context, route | Indicates the total number of exchanges the route has processed successfully since route start-up or the last reset operation. | -| camel.route.exchange.failed | Counter | context, route | Indicates the total number of exchanges that the route has failed to process since route start-up or the last reset operation. | -| camel.route.exchange.failed_handled | Counter | context, route | Indicates the number of exchanges failed and handled by an ExceptionHandler in the route. | -| camel.route.exchange.inflight | UpDownCounter | context, route | Indicates the number of exchanges currently transiting the route. | -| camel.route.exchange.processing.delta_time | Gauge | context, route | Indicates the difference, in milliseconds, of the Processing Time of the last two exchanges transited the route. | -| camel.route.exchange.processing.last_time | Gauge | context, route | Indicates the time, in milliseconds, it took the route to process the last exchange. | -| camel.route.exchange.processing.max_time | Gauge | context, route | Indicates the longest time, in milliseconds, to process an exchange since the route start-up or the last reset operation. | -| camel.route.exchange.processing.mean_time | Gauge | context, route | Indicates the mean processing time, in milliseconds, for all exchanges processed since the route start-up or the last reset operation. | -| camel.route.exchange.processing.min_time | Gauge | context, route | Indicates the shortest time, in milliseconds, to process an exchange since the route start-up or the last reset operation. | -| camel.route.exchange.processing.time | Counter | context, route | Indicates the total processing time, in milliseconds, of all exchanges the selected processed since route start-up or the last reset operation. | -| camel.route.exchange.redelivered | Counter | context, route | Number of exchanges redelivered (internal only) since route start-up or the last reset operation. | -| camel.route.exchange.redelivered_external | Counter | context, route | The total number of all external initiated redeliveries (such as from JMS broker) since the route start-up or the last reset operation. | -| camel.processor.exchange | Counter | context, route, processor, destination | Indicates the total number of exchanges, passed or failed, that the selected processor has processed since processor start-up or the last reset operation. | -| camel.processor.exchange.completed | Counter | context, route, processor, destination | Indicates the total number of exchanges the selected processor has processed successfully since processor start-up or the last reset operation. | -| camel.processor.exchange.failed | Counter | context, route, processor, destination | Indicates the total number of exchanges that the selected processor has failed to process since processor start-up or the last reset operation. | -| camel.processor.exchange.inflight | UpDownCounter | context, route, processor, destination | Indicates the number of exchanges currently transiting the processor. | -| camel.processor.exchange.failed_handled | Counter | context, route, processor, destination | Indicates the number of exchanges failed and handled by an ExceptionHandler in the context. | -| camel.processor.exchange.processing.delta_time | Gauge | context, route, processor, destination | Indicates the difference, in milliseconds, of the Processing Time of the last two exchanges transited the selected processor. | -| camel.processor.exchange.processing.last_time | Gauge | context, route, processor, destination | Indicates the time, in milliseconds, it took the selected processor to process the last exchange. | -| camel.processor.exchange.processing.max_time | Gauge | context, route, processor, destination | Indicates the longest time, in milliseconds, to process an exchange since processor start-up or the last reset operation. | -| camel.processor.exchange.processing.mean_time | Gauge | context, route, processor, destination | Indicates the mean processing time, in milliseconds, for all exchanges processed since processor start-up or the last reset operation. | -| camel.processor.exchange.processing.min_time | Gauge | context, route, processor, destination | Indicates the shortest time, in milliseconds, to process an exchange since processor start-up or the last reset operation. | -| camel.processor.exchange.processing.time | Counter | context, route, processor, destination | Indicates the total processing time, in milliseconds, to process all exchanges since start-up or the last reset operation. | -| camel.processor.exchange.redelivered | Counter | context, route, processor, destination | Number of exchanges redelivered (internal only) since selected processor start-up or the last reset operation. | -| camel.processor.exchange.redelivered_external | Counter | context, route, processor, destination | The total number of all external initiated redeliveries (such as from JMS broker) since processor start-up or the last reset operation. | -| camel.threadpool.active | UpDownCounter | context, route | The approximate number of threads that are actively executing tasks. | -| camel.threadpool.pool.size | UpDownCounter | context, route | The current number of threads in the pool. | -| camel.threadpool.pool.largest_size | Gauge | context, route | The largest number of threads that have ever simultaneously been in the pool. | -| camel.threadpool.task | Counter | context, route | The approximate total number of tasks that have ever been scheduled for execution. | -| camel.threadpool.task.completed | Counter | context, route | The approximate total number of tasks that have completed execution. Because the states of tasks and threads may change dynamically during computation, the returned value is only an approximation, but one that does not ever decrease across successive calls. | -| camel.threadpool.task.queue_size | UpDownCounter | context, route | The number of Tasks in the Task Queue. | +| Metric Name | Type | Attributes | Description | +|------------------------------------------------|---------------|-----------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| +| camel.context.exchange | Counter | context, camel_version, package_scan_class_resolver | Indicates the total number of exchanges, passed or failed, processed since context start-up or the last reset operation. | +| camel.context.exchange.completed | Counter | context, camel_version, package_scan_class_resolver | Indicates the total number of exchanges processed successfully since context start-up or the last reset operation. | +| camel.context.exchange.failed | Counter | context, camel_version, package_scan_class_resolver | Indicates the total number of exchanges that failed to process since context start-up or the last reset operation. | +| camel.context.exchange.failed_handled | Counter | context, camel_version, package_scan_class_resolver | Indicates the number of exchanges failed and handled by an ExceptionHandler in the context. | +| camel.context.exchange.inflight | UpDownCounter | context, camel_version, package_scan_class_resolver | Indicates the number of exchanges currently transiting the context. | +| camel.context.exchange.processing.delta_time | Gauge | context, camel_version, package_scan_class_resolver | Indicates the difference, in milliseconds, of the Processing Time of the last two exchanges transited the context. | +| camel.context.exchange.processing.last_time | Gauge | context, camel_version, package_scan_class_resolver | Indicates the time, in milliseconds, it took to process the last exchange. | +| camel.context.exchange.processing.max_time | Gauge | context, camel_version, package_scan_class_resolver | Indicates the longest time, in milliseconds, to process an exchange since context start-up or the last reset operation. | +| camel.context.exchange.processing.mean_time | Gauge | context, camel_version, package_scan_class_resolver | Indicates the mean processing time, in milliseconds, for all exchanges processed since context start-up or the last reset operation. | +| camel.context.exchange.processing.min_time | Gauge | context, camel_version, package_scan_class_resolver | Indicates the shortest time, in milliseconds, to process an exchange since context start-up or the last reset operation. | +| camel.context.exchange.processing.time | Counter | context, camel_version, package_scan_class_resolver | Indicates the total processing time, in milliseconds, to process all exchanges since context start-up or the last reset operation. | +| camel.context.exchange.redelivered | Counter | context, camel_version, package_scan_class_resolver | Number of exchanges redelivered (internal only) since context start-up or the last reset operation. | +| camel.context.exchange.redelivered_external | Counter | context, camel_version, package_scan_class_resolver | The total number of all external initiated redeliveries (such as from JMS broker) since context start-up or the last reset operation. | +| camel.context.route.started | UpDownCounter | context, camel_version, package_scan_class_resolver | Indicates the number of routes started successfully since context start-up or the last reset operation. | +| camel.context.route.added | Counter | context, camel_version, package_scan_class_resolver | Indicates the total number of routes added successfully since context start-up or the last reset operation. | +| camel.route.exchange | Counter | context, route | Indicates the total number of exchanges, passed or failed, that the route has processed since route start-up or the last reset operation. | +| camel.route.exchange.completed | Counter | context, route | Indicates the total number of exchanges the route has processed successfully since route start-up or the last reset operation. | +| camel.route.exchange.failed | Counter | context, route | Indicates the total number of exchanges that the route has failed to process since route start-up or the last reset operation. | +| camel.route.exchange.failed_handled | Counter | context, route | Indicates the number of exchanges failed and handled by an ExceptionHandler in the route. | +| camel.route.exchange.inflight | UpDownCounter | context, route | Indicates the number of exchanges currently transiting the route. | +| camel.route.exchange.processing.delta_time | Gauge | context, route | Indicates the difference, in milliseconds, of the Processing Time of the last two exchanges transited the route. | +| camel.route.exchange.processing.last_time | Gauge | context, route | Indicates the time, in milliseconds, it took the route to process the last exchange. | +| camel.route.exchange.processing.max_time | Gauge | context, route | Indicates the longest time, in milliseconds, to process an exchange since the route start-up or the last reset operation. | +| camel.route.exchange.processing.mean_time | Gauge | context, route | Indicates the mean processing time, in milliseconds, for all exchanges processed since the route start-up or the last reset operation. | +| camel.route.exchange.processing.min_time | Gauge | context, route | Indicates the shortest time, in milliseconds, to process an exchange since the route start-up or the last reset operation. | +| camel.route.exchange.processing.time | Counter | context, route | Indicates the total processing time, in milliseconds, of all exchanges the selected processed since route start-up or the last reset operation. | +| camel.route.exchange.redelivered | Counter | context, route | Number of exchanges redelivered (internal only) since route start-up or the last reset operation. | +| camel.route.exchange.redelivered_external | Counter | context, route | The total number of all external initiated redeliveries (such as from JMS broker) since the route start-up or the last reset operation. | +| camel.processor.exchange | Counter | context, route, processor, destination | Indicates the total number of exchanges, passed or failed, that the selected processor has processed since processor start-up or the last reset operation. | +| camel.processor.exchange.completed | Counter | context, route, processor, destination | Indicates the total number of exchanges the selected processor has processed successfully since processor start-up or the last reset operation. | +| camel.processor.exchange.failed | Counter | context, route, processor, destination | Indicates the total number of exchanges that the selected processor has failed to process since processor start-up or the last reset operation. | +| camel.processor.exchange.inflight | UpDownCounter | context, route, processor, destination | Indicates the number of exchanges currently transiting the processor. | +| camel.processor.exchange.failed_handled | Counter | context, route, processor, destination | Indicates the number of exchanges failed and handled by an ExceptionHandler in the context. | +| camel.processor.exchange.processing.delta_time | Gauge | context, route, processor, destination | Indicates the difference, in milliseconds, of the Processing Time of the last two exchanges transited the selected processor. | +| camel.processor.exchange.processing.last_time | Gauge | context, route, processor, destination | Indicates the time, in milliseconds, it took the selected processor to process the last exchange. | +| camel.processor.exchange.processing.max_time | Gauge | context, route, processor, destination | Indicates the longest time, in milliseconds, to process an exchange since processor start-up or the last reset operation. | +| camel.processor.exchange.processing.mean_time | Gauge | context, route, processor, destination | Indicates the mean processing time, in milliseconds, for all exchanges processed since processor start-up or the last reset operation. | +| camel.processor.exchange.processing.min_time | Gauge | context, route, processor, destination | Indicates the shortest time, in milliseconds, to process an exchange since processor start-up or the last reset operation. | +| camel.processor.exchange.processing.time | Counter | context, route, processor, destination | Indicates the total processing time, in milliseconds, to process all exchanges since start-up or the last reset operation. | +| camel.processor.exchange.redelivered | Counter | context, route, processor, destination | Number of exchanges redelivered (internal only) since selected processor start-up or the last reset operation. | +| camel.processor.exchange.redelivered_external | Counter | context, route, processor, destination | The total number of all external initiated redeliveries (such as from JMS broker) since processor start-up or the last reset operation. | +| camel.threadpool.active | UpDownCounter | context, route, pool_id | The approximate number of threads that are actively executing tasks. | +| camel.threadpool.pool.size | UpDownCounter | context, route, pool_id | The current number of threads in the pool. | +| camel.threadpool.pool.core_size | UpDownCounter | context, route, pool_id | The number of threads that are always kept in the pool, even if they are idle. | +| camel.threadpool.pool.largest_size | Gauge | context, route, pool_id | The largest number of threads that have ever simultaneously been in the pool. | +| camel.threadpool.task | Counter | context, route, pool_id | The approximate total number of tasks that have ever been scheduled for execution. | +| camel.threadpool.task.completed | Counter | context, route, pool_id | The approximate total number of tasks that have completed execution. Because the states of tasks and threads may change dynamically during computation, the returned value is only an approximation, but one that does not ever decrease across successive calls. | +| camel.threadpool.task.queue_size | UpDownCounter | context, route, pool_id | The number of Tasks in the Task Queue. | diff --git a/instrumentation/jmx-metrics/javaagent/src/main/resources/jmx/rules/camel.yaml b/instrumentation/jmx-metrics/javaagent/src/main/resources/jmx/rules/camel.yaml index a34fa04a437f..581278795dd3 100644 --- a/instrumentation/jmx-metrics/javaagent/src/main/resources/jmx/rules/camel.yaml +++ b/instrumentation/jmx-metrics/javaagent/src/main/resources/jmx/rules/camel.yaml @@ -1,45 +1,59 @@ --- rules: + + # Context Level Metrics + - bean: org.apache.camel:context=*,type=context,name=* prefix: camel.context. metricAttribute: context: param(context) - camelVersion: beanattr(CamelVersion) + camel_version: beanattr(CamelVersion) + package_scan_class_resolver: beanattr(PackageScanClassResolver) mapping: + StartedRoutes: + metric: route.started + type: updowncounter + unit: "{route}" + desc: Indicates the number of routes started successfully since context start-up or the last reset operation. + TotalRoutes: + metric: route.added + type: counter + unit: "{route}" + desc: Indicates the total number of routes added successfully since context start-up or the last reset operation. ExchangesCompleted: metric: exchange.completed type: counter - unit: "{exchanges}" + unit: "{exchange}" desc: Indicates the total number of exchanges processed successfully since context start-up or the last reset operation. ExchangesFailed: metric: exchange.failed type: counter - unit: "{exchanges}" + unit: "{exchange}" desc: Indicates the total number of exchanges that failed to process since context start-up or the last reset operation. ExchangesInflight: metric: exchange.inflight type: updowncounter - unit: "{exchanges}" + unit: "{exchange}" desc: Indicates the number of exchanges currently transiting the context. ExchangesTotal: metric: exchange type: counter - unit: "{exchanges}" + unit: "{exchange}" desc: Indicates the total number of exchanges, passed or failed, processed context start-up or the last reset operation. FailuresHandled: metric: exchange.failed_handled - unit: "{exchanges}" + unit: "{exchange}" type: counter desc: Indicates the number of exchanges failed and handled by an ExceptionHandler in the context. Redeliveries: metric: exchange.redelivered type: counter - unit: "{exchanges}" + unit: "{exchange}" desc: Number of exchanges redelivered (internal only) since context start-up or the last reset operation. ExternalRedeliveries: metric: exchange.redelivered_external type: counter - unit: "{exchanges}" + unit: "{exchange}" desc: The total number of all external initiated redeliveries (such as from JMS broker) since context start-up or the last reset operation. MaxProcessingTime: metric: exchange.processing.max_time @@ -72,7 +86,7 @@ rules: unit: ms desc: Indicates the total processing time, in milliseconds, to process all exchanges since context start-up or the last reset operation. -# Route Level metrics + # Route Level metrics - bean: org.apache.camel:context=*,type=routes,name=* prefix: camel.route. @@ -83,37 +97,37 @@ rules: ExchangesCompleted: metric: exchange.completed type: counter - unit: "{exchanges}" + unit: "{exchange}" desc: Indicates the total number of exchanges the route has processed successfully since route start-up or the last reset operation. ExchangesFailed: metric: exchange.failed type: counter - unit: "{exchanges}" + unit: "{exchange}" desc: Indicates the total number of exchanges that the route has failed to process since route start-up or the last reset operation. ExchangesInflight: metric: exchange.inflight type: updowncounter - unit: "{exchanges}" + unit: "{exchange}" desc: Indicates the number of exchanges currently transiting the route. ExchangesTotal: metric: exchange - unit: "{exchanges}" + unit: "{exchange}" type: counter desc: Indicates the total number of exchanges, passed or failed, that the route has processed since route start-up or the last reset operation. FailuresHandled: metric: exchange.failed_handled - unit: "{exchanges}" + unit: "{exchange}" type: counter desc: Indicates the number of exchanges failed and handled by an ExceptionHandler in the route. ExternalRedeliveries: metric: exchange.redelivered_external - unit: "{exchanges}" + unit: "{exchange}" type: counter desc: The total number of all external initiated redeliveries (such as from JMS broker) since the route start-up or the last reset operation. Redeliveries: metric: exchange.redelivered type: counter - unit: "{exchanges}" + unit: "{exchange}" desc: Number of exchanges redelivered (internal only) since route start-up or the last reset operation. MaxProcessingTime: metric: exchange.processing.max_time @@ -146,8 +160,7 @@ rules: unit: ms desc: Indicates the total processing time, in milliseconds, of all exchanges the selected processed since route start-up or the last reset operation. - -# Processor level Metrics + # Processor Level Metrics - bean: org.apache.camel:context=*,type=processors,name=* prefix: camel.processor. @@ -160,37 +173,37 @@ rules: ExchangesCompleted: metric: exchange.completed type: counter - unit: "{exchanges}" + unit: "{exchange}" desc: Indicates the total number of exchanges the selected processor has processed successfully since processor start-up or the last reset operation. ExchangesFailed: metric: exchange.failed type: counter - unit: "{exchanges}" + unit: "{exchange}" desc: Indicates the total number of exchanges that the selected processor has failed to process since processor start-up or the last reset operation. ExchangesInflight: metric: exchange.inflight type: updowncounter - unit: "{exchanges}" + unit: "{exchange}" desc: Indicates the number of exchanges currently transiting the processor. ExchangesTotal: metric: exchange type: counter - unit: "{exchanges}" + unit: "{exchange}" desc: Indicates the total number of exchanges, passed or failed, that the selected processor has processed since processor start-up or the last reset operation. FailuresHandled: metric: exchange.failed_handled - unit: "{exchanges}" + unit: "{exchange}" type: counter desc: Indicates the number of exchanges failed and handled by an ExceptionHandler in the context. ExternalRedeliveries: metric: exchange.redelivered_external type: counter - unit: "{exchanges}" + unit: "{exchange}" desc: The total number of all external initiated redeliveries (such as from JMS broker) since processor start-up or the last reset operation. Redeliveries: metric: exchange.redelivered type: counter - unit: "{exchanges}" + unit: "{exchange}" desc: Number of exchanges redelivered (internal only) since selected processor start-up or the last reset operation. MaxProcessingTime: metric: exchange.processing.max_time @@ -223,41 +236,48 @@ rules: unit: ms desc: Indicates the total processing time, in milliseconds, to process all exchanges since start-up or the last reset operation. - + # Thread Pools - bean: org.apache.camel:context=*,type=threadpools,name=* prefix: camel.threadpool. metricAttribute: route: beanattr(RouteId) context: param(context) + pool_id: beanattr(Id) mapping: ActiveCount: metric: active type: updowncounter - unit: "{threads}" + unit: "{thread}" desc: The approximate number of threads that are actively executing tasks. CompletedTaskCount: metric: task.completed type: counter - unit: "{tasks}" + unit: "{task}" desc: The approximate total number of tasks that have completed execution. Because the states of tasks and threads may change dynamically during computation, the returned value is only an approximation, but one that does not ever decrease across successive calls. PoolSize: metric: pool.size type: updowncounter - unit: "{threads}" + unit: "{thread}" desc: The current number of threads in the pool. + CorePoolSize: + metric: pool.core_size + type: updowncounter + unit: "{thread}" + desc: The number of threads that are always kept in the pool, even if they are idle. LargestPoolSize: metric: pool.largest_size type: gauge - unit: "{threads}" + unit: "{thread}" desc: The largest number of threads that have ever simultaneously been in the pool. TaskCount: metric: task type: counter - unit: "{tasks}" + unit: "{task}" desc: The approximate total number of tasks that have ever been scheduled for execution. TaskQueueSize: metric: task.queue_size type: updowncounter unit: "{threads}" desc: The number of Tasks in the Task Queue. +