[
https://issues.apache.org/jira/browse/CAMEL-19137?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Claus Ibsen updated CAMEL-19137:
--------------------------------
Issue Type: Improvement (was: New Feature)
> Favor CompositeMeterRegistry instances in Camel registry
> --------------------------------------------------------
>
> Key: CAMEL-19137
> URL: https://issues.apache.org/jira/browse/CAMEL-19137
> Project: Camel
> Issue Type: Improvement
> Components: camel-micrometer
> Affects Versions: 3.18.3
> Reporter: Adriano Marcondes Machado
> Priority: Minor
> Fix For: 3.20.3, 3.21.0, 4.0-M3, 4.0
>
>
> When Spring Boot detects more than one instance of `MeterRegistry` in the
> application context configuration (for example, both `meter-registry-jmx` and
> `meter-registry-prometheus` are on the classpath and the actuator endpoint
> for Prometheus is enabled), the auto-configuration adds an instance of
> `CompositeMeterRegistry` and configures it as the primary bean.
> When the micrometer component starts, it looks for an instance of
> `MeterRegistry` on Camel registry with the name
> `MicrometerConstants.METRICS_REGISTRY_NAME`. If not found, the component
> tries to locate a single instance of any `MeterRegistry` object on the
> registry.
> In the previous example configuration, there will be 3 instances of
> `MeterRegistry`, and the current behavior is to create a new instance of
> `MeterRegistry` to use.
> This changes the default behavior to look first for instances of
> `CompositeMeterRegistry` before looking for instances of `MeterRegistry`.
>
--
This message was sent by Atlassian Jira
(v8.20.10#820010)