I have found on several locations how to use Spring boot to make a custom error page but I cannot seem to figure out how to make it show a stack trace.
This is what I have:
@Bean
public EmbeddedServletContainerCustomizer containerCustomizer() {
return new EmbeddedServletContainerCustomizer() {
@Override
public void customize(ConfigurableEmbeddedServletContainer container) {
ErrorPage error404Page = new ErrorPage(HttpStatus.NOT_FOUND, "/WEB-INF/jsp/app/404.jsp");
ErrorPage error500Page = new ErrorPage(HttpStatus.INTERNAL_SERVER_ERROR, "/WEB-INF/jsp/app/500.jsp");
container.addErrorPages(error404Page, error500Page);
}
};
}
Any ideas how I could figure this out or how to get the stack trace to begin with?
from Newest questions tagged java - Stack Overflow http://ift.tt/1Id9CcY
via IFTTT
Aucun commentaire:
Enregistrer un commentaire