Uploaded image for project: 'OFBiz'
  1. OFBiz
  2. OFBIZ-9847

setLocaleFromBrowser request missing for webpos component

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: Trunk
    • Fix Version/s: Upcoming Release
    • Component/s: webpos
    • Labels:
      None

      Description

      Step to regenerate:
      Login to webpos component (https://localhost:8443/webpos/control/main)

      Error in logs:

      2017-10-15 02:24:10,521 |jsse-nio-8443-exec-3 |ControlServlet                |E| Error in request handler: 
      org.apache.ofbiz.webapp.control.RequestHandlerException: Unknown request [setLocaleFromBrowser]; this request does not exist or cannot be called directly.
              at org.apache.ofbiz.webapp.control.RequestHandler.doRequest(RequestHandler.java:197) ~[ofbiz.jar:?]
              at org.apache.ofbiz.webapp.control.ControlServlet.doGet(ControlServlet.java:212) [ofbiz.jar:?]
              at org.apache.ofbiz.webapp.control.ControlServlet.doPost(ControlServlet.java:87) [ofbiz.jar:?]
              at javax.servlet.http.HttpServlet.service(HttpServlet.java:706) [javax.servlet-api-4.0.0.jar:4.0.0]
              at javax.servlet.http.HttpServlet.service(HttpServlet.java:791) [javax.servlet-api-4.0.0.jar:4.0.0]
              at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231) [tomcat-catalina-8.5.23.jar:8.5.23]
              at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) [tomcat-catalina-8.5.23.jar:8.5.23]
              at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52) [tomcat-embed-websocket-8.0.39.jar:8.0.39]
              at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) [tomcat-catalina-8.5.23.jar:8.5.23]
              at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) [tomcat-catalina-8.5.23.jar:8.5.23]
              at org.apache.ofbiz.webapp.control.ContextFilter.doFilter(ContextFilter.java:196) [ofbiz.jar:?]
              at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) [tomcat-catalina-8.5.23.jar:8.5.23]
              at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) [tomcat-catalina-8.5.23.jar:8.5.23]
              at org.apache.ofbiz.webapp.control.ControlFilter.doFilter(ControlFilter.java:157) [ofbiz.jar:?]
              at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) [tomcat-catalina-8.5.23.jar:8.5.23]
              at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) [tomcat-catalina-8.5.23.jar:8.5.23]
              at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:199) [tomcat-catalina-8.5.23.jar:8.5.23]
              at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:96) [tomcat-catalina-8.5.23.jar:8.5.23]
              at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:478) [tomcat-catalina-8.5.23.jar:8.5.23]
              at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:140) [tomcat-catalina-8.5.23.jar:8.5.23]
              at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:81) [tomcat-catalina-8.5.23.jar:8.5.23]
              at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:87) [tomcat-catalina-8.5.23.jar:8.5.23]
              at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:650) [tomcat-catalina-8.5.23.jar:8.5.23]
              at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:342) [tomcat-catalina-8.5.23.jar:8.5.23]
              at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:803) [tomcat-coyote-8.5.23.jar:8.5.23]
              at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66) [tomcat-coyote-8.5.23.jar:8.5.23]
              at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:868) [tomcat-coyote-8.5.23.jar:8.5.23]
              at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1459) [tomcat-coyote-8.5.23.jar:8.5.23]
              at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49) [tomcat-coyote-8.5.23.jar:8.5.23]
              at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) [?:1.8.0_60]
              at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) [?:1.8.0_60]
              at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) [tomcat-util-8.5.23.jar:8.5.23]
              at java.lang.Thread.run(Thread.java:745) [?:1.8.0_60]
      
      
      1. OFBIZ-9847.patch
        0.7 kB
        Aditya Sharma

        Issue Links

          Activity

          Hide
          mbrohl Michael Brohl added a comment -

          Hi Aditya Sharma,

          this seems to be a duplicate of OFBIZ-9379.

          Show
          mbrohl Michael Brohl added a comment - Hi Aditya Sharma , this seems to be a duplicate of OFBIZ-9379 .
          Hide
          aditya.sharma Aditya Sharma added a comment -

          Hi Michael Brohl,
          They seem to be similar at first instance but in this case, common-controller is not included in webpos controller so RequestHandler couldn't find the request itself.
          Adding a patch for it.

          Show
          aditya.sharma Aditya Sharma added a comment - Hi Michael Brohl , They seem to be similar at first instance but in this case, common-controller is not included in webpos controller so RequestHandler couldn't find the request itself. Adding a patch for it.
          Hide
          jacques.le.roux Jacques Le Roux added a comment -

          Thanks Aditya,

          Your patch is in
          trunk r1812213
          R16.11 r1812214

          Show
          jacques.le.roux Jacques Le Roux added a comment - Thanks Aditya, Your patch is in trunk r1812213 R16.11 r1812214
          Hide
          aditya.sharma Aditya Sharma added a comment -

          Thanks Jacques
          I think backporting is not needed as OFBIZ-9264 is committed to trunk only.

          Show
          aditya.sharma Aditya Sharma added a comment - Thanks Jacques I think backporting is not needed as OFBIZ-9264 is committed to trunk only.
          Hide
          jacques.le.roux Jacques Le Roux added a comment -

          Thanks Aditya, missed that point indeed.

          I have reverted in R16 and also changed to only put the necessary in trunk, I mean

              <!-- Set local from user's browser -->
              <request-map uri="setLocaleFromBrowser">
                  <security https="false" auth="false"/>
                  <event type="service" invoke="setLocaleFromBrowser"/>
                  <response name="success" type="request" value="json"/>
                  <response name="error" type="request" value="json"/>
              </request-map>
          

          the include of the whole common-controller is not needed

          Show
          jacques.le.roux Jacques Le Roux added a comment - Thanks Aditya, missed that point indeed. I have reverted in R16 and also changed to only put the necessary in trunk, I mean <!-- Set local from user's browser --> <request-map uri= "setLocaleFromBrowser" > <security https= " false " auth= " false " /> <event type= "service" invoke= "setLocaleFromBrowser" /> <response name= "success" type= "request" value= "json" /> <response name= "error" type= "request" value= "json" /> </request-map> the include of the whole common-controller is not needed
          Hide
          aditya.sharma Aditya Sharma added a comment -

          That's more appropriate.
          Thanks Jacques

          Show
          aditya.sharma Aditya Sharma added a comment - That's more appropriate. Thanks Jacques

            People

            • Assignee:
              jacques.le.roux Jacques Le Roux
              Reporter:
              aditya.sharma Aditya Sharma
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development