What we'd like to do

We'd like to reuse the excellent rest template metrics interceptor built into spring boot from our existing spring application. Upgrading the application to spring boot is backlogged, but currently out of scope.

Problems encountered

Pulling in spring-boot-actuator without spring-boot (see below) fails as spring-boot-actuator depends on classes form spring-boot-web.

<dependency>
    <groupId>org.springframework.boot</groupId>
    <artifactId>spring-boot-actuator</artifactId>
    <exclusions>
        <exclusion>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot</artifactId>
        </exclusion>
    </exclusions>
</dependency>

Workaround

We vendored in some files from the actuate/metrics/web/client directory. Keeping them up to date is a maintenance headache. We hope to be converted to spring boot soon.

Suggestion

Move the metrics stuff to a common lib or spring boot core instead of having it in boot native.

Comment From: snicoll

Thanks for the proposal but we have no intention of moving such feature outside of Spring Boot. In the meantime, I suggest keeping your copy until your move to Spring Boot proper.