spring-httpserver-timings icon indicating copy to clipboard operation
spring-httpserver-timings copied to clipboard

Allow using a different annotation such as OpenTracing or NewRelic

Open mridang opened this issue 2 years ago • 0 comments

Hi. I love this project and would like to use it on a large codebase. The codebase itself uses NewRelic for instrumentation and so adding a new annotation would be tedious.

Any chance you could add support for using custom annotations such as NewRelic's @Trace annotation or OpenTracing's @Span annotation?

The main Spring context could have an annotation that would allow you to choose the tracing framework e.g.

@SpringBootApplication
@EnableRequestCorrelation
@EnableServerTiming(using = Trace.class)
public class Application {

    @SuppressWarnings("resource")
    public static void main(String[] args) {
        SpringApplication.run(Application.class, args);
    }
}

mridang avatar May 11 '22 08:05 mridang