Giter Site home page Giter Site logo

Comments (5)

mmuruev avatar mmuruev commented on May 4, 2024
    @ResponseStatus(HttpStatus.NOT_FOUND)
    @ResponseBody
    public ErrorMessage processNoHandlerFoundException(NoHandlerFoundException ex) {
        log.warn("NoHandlerFoundException not found: ", ex);

        return ErrorMessage.builder()
                .error(ex.getMessage())
                .build();
    }

@ControllerAdvice like this helps. Where ErrorMessage just POJO with String error field.

from spring-boot.

wilkinsona avatar wilkinsona commented on May 4, 2024

Thanks for the report. I can see from the stack trace that there are a number of filters involved in the processing of the request but I can't tell what they are based on the information provided thus far. Can you please provide a minimal sample that reproduces the problem so that we can see exactly what's involved?

from spring-boot.

mmuruev avatar mmuruev commented on May 4, 2024

Well I'm trying to. But it seems not so easy cant reproduce it yet in sandbox, But I've found out that this issue disappears if I remove controller advice completely also in this case I've got standard error output from Spring.
Filters
image

from spring-boot.

mmuruev avatar mmuruev commented on May 4, 2024
processUnhandledError:209, ExceptionsController (platform.api.controller.error)
invokeVirtual:-1, LambdaForm$DMH/0x0000706958080c00 (java.lang.invoke)
invoke:-1, LambdaForm$MH/0x00007069588c8800 (java.lang.invoke)
invokeExact_MT:-1, LambdaForm$MH/0x0000706958002800 (java.lang.invoke)
invokeImpl:155, DirectMethodHandleAccessor (jdk.internal.reflect)
invoke:103, DirectMethodHandleAccessor (jdk.internal.reflect)
invoke:580, Method (java.lang.reflect)
doInvoke:255, InvocableHandlerMethod (org.springframework.web.method.support)
invokeForRequest:188, InvocableHandlerMethod (org.springframework.web.method.support)
invokeAndHandle:118, ServletInvocableHandlerMethod (org.springframework.web.servlet.mvc.method.annotation)
doResolveHandlerMethodException:432, ExceptionHandlerExceptionResolver (org.springframework.web.servlet.mvc.method.annotation)
doResolveException:74, AbstractHandlerMethodExceptionResolver (org.springframework.web.servlet.handler)
resolveException:175, AbstractHandlerExceptionResolver (org.springframework.web.servlet.handler)
resolveException:80, HandlerExceptionResolverComposite (org.springframework.web.servlet.handler)
processHandlerException:1357, DispatcherServlet (org.springframework.web.servlet)
processDispatchResult:1160, DispatcherServlet (org.springframework.web.servlet)
doDispatch:1106, DispatcherServlet (org.springframework.web.servlet)
doService:979, DispatcherServlet (org.springframework.web.servlet)
processRequest:1014, FrameworkServlet (org.springframework.web.servlet)
doPost:914, FrameworkServlet (org.springframework.web.servlet)
service:590, HttpServlet (jakarta.servlet.http)
service:885, FrameworkServlet (org.springframework.web.servlet)
service:658, HttpServlet (jakarta.servlet.http)
internalDoFilter:206, ApplicationFilterChain (org.apache.catalina.core)
doFilter:150, ApplicationFilterChain (org.apache.catalina.core)
doFilter:51, WsFilter (org.apache.tomcat.websocket.server)
internalDoFilter:175, ApplicationFilterChain (org.apache.catalina.core)
doFilter:150, ApplicationFilterChain (org.apache.catalina.core)
doFilter:101, OncePerRequestFilter (org.springframework.web.filter)
internalDoFilter:175, ApplicationFilterChain (org.apache.catalina.core)
doFilter:150, ApplicationFilterChain (org.apache.catalina.core)
doFilter:110, OncePerRequestFilter (org.springframework.web.filter)
internalDoFilter:175, ApplicationFilterChain (org.apache.catalina.core)
doFilter:150, ApplicationFilterChain (org.apache.catalina.core)
doFilter:101, OncePerRequestFilter (org.springframework.web.filter)
internalDoFilter:175, ApplicationFilterChain (org.apache.catalina.core)
doFilter:150, ApplicationFilterChain (org.apache.catalina.core)
doFilter:101, OncePerRequestFilter (org.springframework.web.filter)
internalDoFilter:175, ApplicationFilterChain (org.apache.catalina.core)
doFilter:150, ApplicationFilterChain (org.apache.catalina.core)
invoke:653, ApplicationDispatcher (org.apache.catalina.core)
processRequest:419, ApplicationDispatcher (org.apache.catalina.core)
doForward:340, ApplicationDispatcher (org.apache.catalina.core)
forward:277, ApplicationDispatcher (org.apache.catalina.core)
renderMergedOutputModel:171, InternalResourceView (org.springframework.web.servlet.view)
render:314, AbstractView (org.springframework.web.servlet.view)
render:1431, DispatcherServlet (org.springframework.web.servlet)
processDispatchResult:1167, DispatcherServlet (org.springframework.web.servlet)
doDispatch:1106, DispatcherServlet (org.springframework.web.servlet)
doService:979, DispatcherServlet (org.springframework.web.servlet)
processRequest:1014, FrameworkServlet (org.springframework.web.servlet)
doPost:914, FrameworkServlet (org.springframework.web.servlet)
service:590, HttpServlet (jakarta.servlet.http)
service:885, FrameworkServlet (org.springframework.web.servlet)
service:658, HttpServlet (jakarta.servlet.http)
internalDoFilter:206, ApplicationFilterChain (org.apache.catalina.core)
doFilter:150, ApplicationFilterChain (org.apache.catalina.core)
doFilter:51, WsFilter (org.apache.tomcat.websocket.server)
internalDoFilter:175, ApplicationFilterChain (org.apache.catalina.core)
doFilter:150, ApplicationFilterChain (org.apache.catalina.core)
doFilterInternal:47, WebConfig$1 (io.onetouch.platform.api)
doFilter:116, OncePerRequestFilter (org.springframework.web.filter)
internalDoFilter:175, ApplicationFilterChain (org.apache.catalina.core)
doFilter:150, ApplicationFilterChain (org.apache.catalina.core)
doFilterInternal:100, RequestContextFilter (org.springframework.web.filter)
doFilter:116, OncePerRequestFilter (org.springframework.web.filter)
internalDoFilter:175, ApplicationFilterChain (org.apache.catalina.core)
doFilter:150, ApplicationFilterChain (org.apache.catalina.core)
doFilterInternal:93, FormContentFilter (org.springframework.web.filter)
doFilter:116, OncePerRequestFilter (org.springframework.web.filter)
internalDoFilter:175, ApplicationFilterChain (org.apache.catalina.core)
doFilter:150, ApplicationFilterChain (org.apache.catalina.core)
doFilter:69, OpenTelemetryHandlerMappingFilter (org.springframework.web.servlet.v6_0)
internalDoFilter:175, ApplicationFilterChain (org.apache.catalina.core)
doFilter:150, ApplicationFilterChain (org.apache.catalina.core)
doFilterInternal:109, ServerHttpObservationFilter (org.springframework.web.filter)
doFilter:116, OncePerRequestFilter (org.springframework.web.filter)
internalDoFilter:175, ApplicationFilterChain (org.apache.catalina.core)
doFilter:150, ApplicationFilterChain (org.apache.catalina.core)
doFilterInternal:201, CharacterEncodingFilter (org.springframework.web.filter)
doFilter:116, OncePerRequestFilter (org.springframework.web.filter)
internalDoFilter:175, ApplicationFilterChain (org.apache.catalina.core)
doFilter:150, ApplicationFilterChain (org.apache.catalina.core)
invoke:167, StandardWrapperValve (org.apache.catalina.core)
invoke:90, StandardContextValve (org.apache.catalina.core)
invoke:482, AuthenticatorBase (org.apache.catalina.authenticator)
invoke:115, StandardHostValve (org.apache.catalina.core)
invoke:93, ErrorReportValve (org.apache.catalina.valves)
invoke:74, StandardEngineValve (org.apache.catalina.core)
service:344, CoyoteAdapter (org.apache.catalina.connector)
service:391, Http11Processor (org.apache.coyote.http11)
process:63, AbstractProcessorLight (org.apache.coyote)
process:896, AbstractProtocol$ConnectionHandler (org.apache.coyote)
doRun:1736, NioEndpoint$SocketProcessor (org.apache.tomcat.util.net)
run:52, SocketProcessorBase (org.apache.tomcat.util.net)
runWorker:1191, ThreadPoolExecutor (org.apache.tomcat.util.threads)
run:659, ThreadPoolExecutor$Worker (org.apache.tomcat.util.threads)
run:63, TaskThread$WrappingRunnable (org.apache.tomcat.util.threads)
runWith:1596, Thread (java.lang)
run:1583, Thread (java.lang)

full stack with 2 iterations

from spring-boot.

spring-projects-issues avatar spring-projects-issues commented on May 4, 2024

If you would like us to look at this issue, please provide the requested information. If the information is not provided within the next 7 days this issue will be closed.

from spring-boot.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.