You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@rocketmq.apache.org by GitBox <gi...@apache.org> on 2020/12/04 10:42:12 UTC

[GitHub] [rocketmq-externals] maixiaohai opened a new issue #658: [rocketmq-console] Login throw NPE when set rocketmq.config.enableDashBoardCollect=false

maixiaohai opened a new issue #658:
URL: https://github.com/apache/rocketmq-externals/issues/658


   **BUG REPORT**
   
   1. Please describe the issue you observed:
   
   - What did you do (The steps to reproduce)?
   I changed the **application.properties** file, 
   set **rocketmq.config.enableDashBoardCollect=false**
   set **rocketmq.config.loginRequired=true**
   When I login the console platform, a NPE was throwed.
   
   I checked the code and found code as followed
   ```
   public void afterPropertiesSet() throws Exception {
           if (configure.isEnableDashBoardCollect()) {
                fileBasedUserInfoStore = new FileBasedUserInfoStore(configure);
            }
        }
   
   ```
   the file load logic controlled by parameter rocketmq.config.enableDashBoardCollect.
   
   2. Please tell us about your environment:
   **console-ng-2.0.0**
   3. Other information (e.g. detailed explanation, logs, related issues, suggestions how to fix, etc):
   error log 
   ```
   [2020-12-04 14:45:38.347] ERROR op=global_exception_handler_print_error
   java.lang.NullPointerException: null
           at org.apache.rocketmq.console.service.impl.UserServiceImpl.queryByUsernameAndPassword(UserServiceImpl.java:54)
           at org.apache.rocketmq.console.controller.LoginController.login(LoginController.java:68)
           at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
           at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
           at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
           at java.lang.reflect.Method.invoke(Method.java:498)
           at org.springframework.web.method.support.InvocableHandlerMethod.doInvoke(InvocableHandlerMethod.java:190)
           at org.springframework.web.method.support.InvocableHandlerMethod.invokeForRequest(InvocableHandlerMethod.java:138)
           at org.springframework.web.servlet.mvc.method.annotation.ServletInvocableHandlerMethod.invokeAndHandle(ServletInvocableHandlerMethod.java:106)
           at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.invokeHandlerMethod(RequestMappingHandlerAdapter.java:888)
           at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.handleInternal(RequestMappingHandlerAdapter.java:793)
           at org.springframework.web.servlet.mvc.method.AbstractHandlerMethodAdapter.handle(AbstractHandlerMethodAdapter.java:87)
           at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:1040)
           at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:943)
           at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:1006)
           at org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:909)
           at javax.servlet.http.HttpServlet.service(HttpServlet.java:660)
           at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:883)
           at javax.servlet.http.HttpServlet.service(HttpServlet.java:741)
           at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231)
           at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
           at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:53)
           at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
           at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
           at org.apache.rocketmq.console.filter.HttpBasicAuthorizedFilter.doFilter(HttpBasicAuthorizedFilter.java:45)
           at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
           at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
           at org.springframework.web.filter.RequestContextFilter.doFilterInternal(RequestContextFilter.java:100)
           at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:119)
           at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
           at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
           at org.springframework.web.filter.FormContentFilter.doFilterInternal(FormContentFilter.java:93)
           at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:119)
           at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
           at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
           at org.springframework.boot.actuate.metrics.web.servlet.WebMvcMetricsFilter.doFilterInternal(WebMvcMetricsFilter.java:108)
           at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:119)
           at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
   ```


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [rocketmq-externals] vongosling closed issue #658: [rocketmq-console] Login throw NPE when set rocketmq.config.enableDashBoardCollect=false

Posted by GitBox <gi...@apache.org>.
vongosling closed issue #658:
URL: https://github.com/apache/rocketmq-externals/issues/658


   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org