Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
public void addFailureHandling(Router router) {
Route route = router.route();
route.handler(LoggerHandler.create());
// this does not get hit on a not found resource, i see the logger hit but my handler never gets hit
route.failureHandler(routingContext -> {
logger.warn("no path found for {}", routingContext.request().uri());
routingContext.request().response().setStatusCode(HttpResponseStatus.NOT_FOUND.code()).end();
});
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.