• Artem Bilan's avatar
    Refactor Spring Integration metrics support · d69e43b4
    Artem Bilan authored
    Update Spring Integration metrics support since Spring Integration
    `4.3.6`+ no longer needs `spring-integration-jmx` enable
    `MessageChannel`, `MessageHandler` and `MessageSource` metrics.
    
    - Add `IntegrationManagementConfiguration` conditional auto-configuration
      to provide `@EnableIntegrationManagement` when JMX is `enabled` or there
      is no `IntegrationManagementConfigurer.MANAGEMENT_CONFIGURER_NAME` bean.
      By default this bean doesn't exist and you explicitly should declare it
      (e.g. via `@EnableIntegrationManagement`) if you would like to collect
      metrics. At the same time Spring Integration enables it when JMX
      management is present (that is a purpose of that new
      `IntegrationManagementConfiguration`)
    
    - Change `SpringIntegrationMetricReader` to read metrics from the
      `IntegrationManagementConfigurer`, not `IntegrationMBeanExporter`
    
    - Change `PublicMetricsAutoConfiguration` to register
      `IntegrationManagementConfigurer.MANAGEMENT_CONFIGURER_NAME` bean if
      not present. Since we are here in `actuator`, therefore we are
      interested in the metrics for SI as well.
    
    - Since we don't need JMX for the metrics any more, remove SI-JMX
      dependency from the `spring-boot-starter-integration`.
    
    - Remove `IntegrationManagementConfiguration` modification from the
      `integrationMbeanExporter()`, since that looks like mutation of an
      external object, when end-user would prefer their own options.
      Therefore we don't need `ObjectProvider<IntegrationManagementConfigurer>`, too
    
    - Add missed `MessageSourceMetrics` gathering for the
      `SpringIntegrationMetricReader`
    
    Closes gh-7722
    d69e43b4
Name
Last commit
Last update
.github Loading commit data...
.mvn Loading commit data...
eclipse Loading commit data...
spring-boot Loading commit data...
spring-boot-actuator Loading commit data...
spring-boot-actuator-docs Loading commit data...
spring-boot-autoconfigure Loading commit data...
spring-boot-cli Loading commit data...
spring-boot-dependencies Loading commit data...
spring-boot-deployment-tests Loading commit data...
spring-boot-devtools Loading commit data...
spring-boot-docs Loading commit data...
spring-boot-full-build Loading commit data...
spring-boot-integration-tests Loading commit data...
spring-boot-parent Loading commit data...
spring-boot-samples Loading commit data...
spring-boot-starters Loading commit data...
spring-boot-test Loading commit data...
spring-boot-test-autoconfigure Loading commit data...
spring-boot-test-support Loading commit data...
spring-boot-tools Loading commit data...
.gitignore Loading commit data...
.settings-template.xml Loading commit data...
.travis.yml Loading commit data...
CODE_OF_CONDUCT.adoc Loading commit data...
CONTRIBUTING.adoc Loading commit data...
LICENSE.txt Loading commit data...
README.adoc Loading commit data...
mvnw Loading commit data...
mvnw.cmd Loading commit data...
pom.xml Loading commit data...