java.lang.NullPointerException: null

Stack Overflow | Felipe A. | 6 months ago
tip
Your exception is missing from the Samebug knowledge base.
Here are the best solutions we found on the Internet.
Click on the to mark the helpful solution and get rewards for you help.
  1. 0

    Java Hash Generator returning nullpointer

    Stack Overflow | 6 months ago | Felipe A.
    java.lang.NullPointerException: null

    Root Cause Analysis

    1. java.lang.NullPointerException

      null

      at com.wsfsistemas.meuveiculocerto.service.UsuarioService.resetPassword()
    2. com.wsfsistemas.meuveiculocerto
      UsuarioController.resetPassword
      1. com.wsfsistemas.meuveiculocerto.service.UsuarioService.resetPassword(UsuarioService.java:50)[classes/:na]
      2. com.wsfsistemas.meuveiculocerto.controller.UsuarioController.resetPassword(UsuarioController.java:45)[classes/:na]
      2 frames
    3. Java RT
      Method.invoke
      1. sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)[na:1.8.0_91]
      2. sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)[na:1.8.0_91]
      3. sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)[na:1.8.0_91]
      4. java.lang.reflect.Method.invoke(Method.java:498)[na:1.8.0_91]
      4 frames
    4. Spring
      InvocableHandlerMethod.invokeForRequest
      1. org.springframework.web.method.support.InvocableHandlerMethod.doInvoke(InvocableHandlerMethod.java:221)[spring-web-4.2.5.RELEASE.jar:4.2.5.RELEASE]
      2. org.springframework.web.method.support.InvocableHandlerMethod.invokeForRequest(InvocableHandlerMethod.java:136)[spring-web-4.2.5.RELEASE.jar:4.2.5.RELEASE]
      2 frames
    5. Spring MVC
      FrameworkServlet.doPut
      1. org.springframework.web.servlet.mvc.method.annotation.ServletInvocableHandlerMethod.invokeAndHandle(ServletInvocableHandlerMethod.java:110)[spring-webmvc-4.2.5.RELEASE.jar:4.2.5.RELEASE]
      2. org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.invokeHandlerMethod(RequestMappingHandlerAdapter.java:817)[spring-webmvc-4.2.5.RELEASE.jar:4.2.5.RELEASE]
      3. org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.handleInternal(RequestMappingHandlerAdapter.java:731)[spring-webmvc-4.2.5.RELEASE.jar:4.2.5.RELEASE]
      4. org.springframework.web.servlet.mvc.method.AbstractHandlerMethodAdapter.handle(AbstractHandlerMethodAdapter.java:85)[spring-webmvc-4.2.5.RELEASE.jar:4.2.5.RELEASE]
      5. org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:959)[spring-webmvc-4.2.5.RELEASE.jar:4.2.5.RELEASE]
      6. org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:893)[spring-webmvc-4.2.5.RELEASE.jar:4.2.5.RELEASE]
      7. org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:968)[spring-webmvc-4.2.5.RELEASE.jar:4.2.5.RELEASE]
      8. org.springframework.web.servlet.FrameworkServlet.doPut(FrameworkServlet.java:881)[spring-webmvc-4.2.5.RELEASE.jar:4.2.5.RELEASE]
      8 frames
    6. JavaServlet
      HttpServlet.service
      1. javax.servlet.http.HttpServlet.service(HttpServlet.java:651)[tomcat-embed-core-8.0.32.jar:8.0.32]
      1 frame
    7. Spring MVC
      FrameworkServlet.service
      1. org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:844)[spring-webmvc-4.2.5.RELEASE.jar:4.2.5.RELEASE]
      1 frame
    8. JavaServlet
      HttpServlet.service
      1. javax.servlet.http.HttpServlet.service(HttpServlet.java:729)[tomcat-embed-core-8.0.32.jar:8.0.32]
      1 frame
    9. Glassfish Core
      ApplicationFilterChain.doFilter
      1. org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:292)[tomcat-embed-core-8.0.32.jar:8.0.32]
      2. org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:207)[tomcat-embed-core-8.0.32.jar:8.0.32]
      2 frames
    10. Tomcat WS
      WsFilter.doFilter
      1. org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)[tomcat-embed-websocket-8.0.32.jar:8.0.32]
      1 frame
    11. Glassfish Core
      ApplicationFilterChain.doFilter
      1. org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:240)[tomcat-embed-core-8.0.32.jar:8.0.32]
      2. org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:207)[tomcat-embed-core-8.0.32.jar:8.0.32]
      2 frames
    12. Spring
      OncePerRequestFilter.doFilter
      1. org.springframework.web.filter.RequestContextFilter.doFilterInternal(RequestContextFilter.java:99)[spring-web-4.2.5.RELEASE.jar:4.2.5.RELEASE]
      2. org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)[spring-web-4.2.5.RELEASE.jar:4.2.5.RELEASE]
      2 frames
    13. Glassfish Core
      ApplicationFilterChain.doFilter
      1. org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:240)[tomcat-embed-core-8.0.32.jar:8.0.32]
      2. org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:207)[tomcat-embed-core-8.0.32.jar:8.0.32]
      2 frames
    14. Spring
      OncePerRequestFilter.doFilter
      1. org.springframework.web.filter.HttpPutFormContentFilter.doFilterInternal(HttpPutFormContentFilter.java:87)[spring-web-4.2.5.RELEASE.jar:4.2.5.RELEASE]
      2. org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)[spring-web-4.2.5.RELEASE.jar:4.2.5.RELEASE]
      2 frames
    15. Glassfish Core
      ApplicationFilterChain.doFilter
      1. org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:240)[tomcat-embed-core-8.0.32.jar:8.0.32]
      2. org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:207)[tomcat-embed-core-8.0.32.jar:8.0.32]
      2 frames
    16. Spring
      OncePerRequestFilter.doFilter
      1. org.springframework.web.filter.HiddenHttpMethodFilter.doFilterInternal(HiddenHttpMethodFilter.java:77)[spring-web-4.2.5.RELEASE.jar:4.2.5.RELEASE]
      2. org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)[spring-web-4.2.5.RELEASE.jar:4.2.5.RELEASE]
      2 frames
    17. Glassfish Core
      ApplicationFilterChain.doFilter
      1. org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:240)[tomcat-embed-core-8.0.32.jar:8.0.32]
      2. org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:207)[tomcat-embed-core-8.0.32.jar:8.0.32]
      2 frames
    18. Spring
      OncePerRequestFilter.doFilter
      1. org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:121)[spring-web-4.2.5.RELEASE.jar:4.2.5.RELEASE]
      2. org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)[spring-web-4.2.5.RELEASE.jar:4.2.5.RELEASE]
      2 frames
    19. Glassfish Core
      CoyoteAdapter.service
      1. org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:240)[tomcat-embed-core-8.0.32.jar:8.0.32]
      2. org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:207)[tomcat-embed-core-8.0.32.jar:8.0.32]
      3. org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:212)[tomcat-embed-core-8.0.32.jar:8.0.32]
      4. org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:106)[tomcat-embed-core-8.0.32.jar:8.0.32]
      5. org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:502)[tomcat-embed-core-8.0.32.jar:8.0.32]
      6. org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:141)[tomcat-embed-core-8.0.32.jar:8.0.32]
      7. org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:79)[tomcat-embed-core-8.0.32.jar:8.0.32]
      8. org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:88)[tomcat-embed-core-8.0.32.jar:8.0.32]
      9. org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:522)[tomcat-embed-core-8.0.32.jar:8.0.32]
      9 frames
    20. Grizzly HTTP
      NioEndpoint$SocketProcessor.run
      1. org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1095)[tomcat-embed-core-8.0.32.jar:8.0.32]
      2. org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:672)[tomcat-embed-core-8.0.32.jar:8.0.32]
      3. org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1500)[tomcat-embed-core-8.0.32.jar:8.0.32]
      4. org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.run(NioEndpoint.java:1456)[tomcat-embed-core-8.0.32.jar:8.0.32]
      4 frames
    21. Java RT
      ThreadPoolExecutor$Worker.run
      1. java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)[na:1.8.0_91]
      2. java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)[na:1.8.0_91]
      2 frames
    22. Tomcat Util
      TaskThread$WrappingRunnable.run
      1. org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)[tomcat-embed-core-8.0.32.jar:8.0.32]
      1 frame
    23. Java RT
      Thread.run
      1. java.lang.Thread.run(Thread.java:745)[na:1.8.0_91]
      1 frame