I am trying to configure an interceptor in my application and I am not being able to make it work.
In my application configuration class, I have configured in the follow
This approach worked with me
@Configuration public class WebConfiguration extends WebMvcConfigurerAdapter { @Override public void addInterceptors(InterceptorRegistry registry) { registry.addInterceptor(new MyInterceptor()); } }