I am trying to create my own ErrorWebExceptionHandler
in Spring Boot 2 by extending the default one but my application fails to start with the following message:
Please try to add dependency of ServerCodecConfigurer in your constructor
GlobalErrorWebExceptionHandler(ErrorAttributes errorAttributes,
ResourceProperties resourceProperties, ApplicationContext applicationContext, ServerCodecConfigurer configurer) {
super(errorAttributes, resourceProperties, applicationContext);
this.setMessageWriters(configurer.getWriters());
}