java.lang.NullPointerException: null

Stack Overflow | Dieseled UP | 3 months ago
tip
Do you find the tips below useful? Click on the to mark them and say thanks to rafael . Or join the community to write better ones.
  1. 0
    samebug tip
    Check if you added Multipart filter to your web.xml file. Also, take a look here https://goo.gl/ntbxrA for common mistakes related to MultiPart File Upload and how to solve them.
  2. 0
    samebug tip
    If you're not using an embedded servlet container, try do disable the white label in your application.properties, with "server.error.whitelabel.enabled = false" otherwise check this answer on stackoverflow: https://goo.gl/rG0vKE
  3. 0
    samebug tip
    This happens when you read the input as binary stream getInputStream() and character stream getReader, you can only use one way, or you can try this workaround https://goo.gl/IspUjB
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0
    samebug tip
    Check if your path is correct, if it's correct already you have to register your path to the mapping configuration.
  6. 0

    How to set Set<bean> to ObjectMapper

    Stack Overflow | 6 months ago | Ravi Kumar Ravanam
    org.springframework.security.authentication.InternalAuthenticationServiceException

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. java.lang.NullPointerException

      null

      at org.springframework.security.authentication.ProviderManager.authenticate()
    2. spring-security-core
      ProviderManager.authenticate
      1. org.springframework.security.authentication.ProviderManager.authenticate(ProviderManager.java:164)[spring-security-core-4.1.3.RELEASE.jar:4.1.3.RELEASE]
      2. org.springframework.security.authentication.ProviderManager.authenticate(ProviderManager.java:199)[spring-security-core-4.1.3.RELEASE.jar:4.1.3.RELEASE]
      2 frames
    3. Spring Security
      FilterChainProxy$VirtualFilterChain.doFilter
      1. org.springframework.security.web.authentication.UsernamePasswordAuthenticationFilter.attemptAuthentication(UsernamePasswordAuthenticationFilter.java:94)[spring-security-web-4.1.3.RELEASE.jar:4.1.3.RELEASE]
      2. org.springframework.security.web.authentication.AbstractAuthenticationProcessingFilter.doFilter(AbstractAuthenticationProcessingFilter.java:212)[spring-security-web-4.1.3.RELEASE.jar:4.1.3.RELEASE]
      3. org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)[spring-security-web-4.1.3.RELEASE.jar:4.1.3.RELEASE]
      4. org.springframework.security.web.authentication.logout.LogoutFilter.doFilter(LogoutFilter.java:121)[spring-security-web-4.1.3.RELEASE.jar:4.1.3.RELEASE]
      5. org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)[spring-security-web-4.1.3.RELEASE.jar:4.1.3.RELEASE]
      6. org.springframework.security.web.context.SecurityContextPersistenceFilter.doFilter(SecurityContextPersistenceFilter.java:105)[spring-security-web-4.1.3.RELEASE.jar:4.1.3.RELEASE]
      7. org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)[spring-security-web-4.1.3.RELEASE.jar:4.1.3.RELEASE]
      7 frames
    4. org.springframework.security
      WebAsyncManagerIntegrationFilter.doFilterInternal
      1. org.springframework.security.web.context.request.async.WebAsyncManagerIntegrationFilter.doFilterInternal(WebAsyncManagerIntegrationFilter.java:56)[spring-security-web-4.1.3.RELEASE.jar:4.1.3.RELEASE]
      1 frame
    5. Spring
      OncePerRequestFilter.doFilter
      1. org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)[spring-web-4.3.3.RELEASE.jar:4.3.3.RELEASE]
      1 frame
    6. Spring Security
      FilterChainProxy.doFilter
      1. org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)[spring-security-web-4.1.3.RELEASE.jar:4.1.3.RELEASE]
      2. org.springframework.security.web.FilterChainProxy.doFilterInternal(FilterChainProxy.java:214)[spring-security-web-4.1.3.RELEASE.jar:4.1.3.RELEASE]
      3. org.springframework.security.web.FilterChainProxy.doFilter(FilterChainProxy.java:177)[spring-security-web-4.1.3.RELEASE.jar:4.1.3.RELEASE]
      3 frames
    7. Spring
      DelegatingFilterProxy.doFilter
      1. org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:346)[spring-web-4.3.3.RELEASE.jar:4.3.3.RELEASE]
      2. org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:262)[spring-web-4.3.3.RELEASE.jar:4.3.3.RELEASE]
      2 frames
    8. Glassfish Core
      ApplicationFilterChain.doFilter
      1. org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:192)[tomcat-embed-core-8.5.5.jar:8.5.5]
      2. org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:165)[tomcat-embed-core-8.5.5.jar:8.5.5]
      2 frames
    9. Spring
      OncePerRequestFilter.doFilter
      1. org.springframework.web.filter.RequestContextFilter.doFilterInternal(RequestContextFilter.java:99)[spring-web-4.3.3.RELEASE.jar:4.3.3.RELEASE]
      2. org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)[spring-web-4.3.3.RELEASE.jar:4.3.3.RELEASE]
      2 frames
    10. Glassfish Core
      ApplicationFilterChain.doFilter
      1. org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:192)[tomcat-embed-core-8.5.5.jar:8.5.5]
      2. org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:165)[tomcat-embed-core-8.5.5.jar:8.5.5]
      2 frames
    11. Spring
      OncePerRequestFilter.doFilter
      1. org.springframework.web.filter.HttpPutFormContentFilter.doFilterInternal(HttpPutFormContentFilter.java:89)[spring-web-4.3.3.RELEASE.jar:4.3.3.RELEASE]
      2. org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)[spring-web-4.3.3.RELEASE.jar:4.3.3.RELEASE]
      2 frames
    12. Glassfish Core
      ApplicationFilterChain.doFilter
      1. org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:192)[tomcat-embed-core-8.5.5.jar:8.5.5]
      2. org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:165)[tomcat-embed-core-8.5.5.jar:8.5.5]
      2 frames
    13. Spring
      OncePerRequestFilter.doFilter
      1. org.springframework.web.filter.HiddenHttpMethodFilter.doFilterInternal(HiddenHttpMethodFilter.java:77)[spring-web-4.3.3.RELEASE.jar:4.3.3.RELEASE]
      2. org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)[spring-web-4.3.3.RELEASE.jar:4.3.3.RELEASE]
      2 frames
    14. Glassfish Core
      ApplicationFilterChain.doFilter
      1. org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:192)[tomcat-embed-core-8.5.5.jar:8.5.5]
      2. org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:165)[tomcat-embed-core-8.5.5.jar:8.5.5]
      2 frames
    15. Spring
      OncePerRequestFilter.doFilter
      1. org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:197)[spring-web-4.3.3.RELEASE.jar:4.3.3.RELEASE]
      2. org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)[spring-web-4.3.3.RELEASE.jar:4.3.3.RELEASE]
      2 frames
    16. Glassfish Core
      CoyoteAdapter.service
      1. org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:192)[tomcat-embed-core-8.5.5.jar:8.5.5]
      2. org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:165)[tomcat-embed-core-8.5.5.jar:8.5.5]
      3. org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:198)[tomcat-embed-core-8.5.5.jar:8.5.5]
      4. org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:108)[tomcat-embed-core-8.5.5.jar:8.5.5]
      5. org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:472)[tomcat-embed-core-8.5.5.jar:8.5.5]
      6. org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:140)[tomcat-embed-core-8.5.5.jar:8.5.5]
      7. org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:79)[tomcat-embed-core-8.5.5.jar:8.5.5]
      8. org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:87)[tomcat-embed-core-8.5.5.jar:8.5.5]
      9. org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:349)[tomcat-embed-core-8.5.5.jar:8.5.5]
      9 frames
    17. Grizzly HTTP
      SocketProcessorBase.run
      1. org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:784)[tomcat-embed-core-8.5.5.jar:8.5.5]
      2. org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66)[tomcat-embed-core-8.5.5.jar:8.5.5]
      3. org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:802)[tomcat-embed-core-8.5.5.jar:8.5.5]
      4. org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1410)[tomcat-embed-core-8.5.5.jar:8.5.5]
      5. org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)[tomcat-embed-core-8.5.5.jar:8.5.5]
      5 frames
    18. Java RT
      ThreadPoolExecutor$Worker.run
      1. java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)[na:1.8.0_111]
      2. java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)[na:1.8.0_111]
      2 frames
    19. Tomcat Util
      TaskThread$WrappingRunnable.run
      1. org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)[tomcat-embed-core-8.5.5.jar:8.5.5]
      1 frame
    20. Java RT
      Thread.run
      1. java.lang.Thread.run(Thread.java:745)[na:1.8.0_111]
      1 frame