class MyExtension {
void afterBeanDiscovery(@Observes AfterBeanDiscovery event) {
event.addInterceptor().intercept(InterceptionType.AROUND_INVOKE, (c) -> {
long start = System.currentTimeMillis();
try {
return c.proceed();
} finally {
System.out.println("Time: " + System.currentTimeMillis() - start);
}
}).priority(2600).addBinding(MonitoringBinding.Literal.INSTANCE);
}
}