Uploaded image for project: 'Undertow'
  1. Undertow
  2. UNDERTOW-1599

ServletRequestLineAttribute does not output the original query string after the request is forwarded with new query strings

    Details

      Description

      When a servlet request is forward to a different path with a new query string, ServletRequestLineAttribute (%r) does not output a query string of the original request in the access log.

      For example, when the following dispatcher.forward() is implemented in the application:

      RequestDispatcher dispatcher = request.getRequestDispatcher("/test?foo=bar");
      dispatcher.forward(request, response);
      

      and the following request is sent to the above application:

      $ curl -v http://localhost:8080/example/?aaa=bbb
      

      The access-log should output the original query string (?aaa=bbb), but it output the new query string (?foo=bar) of the forwarded request:

      127.0.0.1 - - [10/Oct/2019:20:20:54 +0900] "GET /example/?foo=bar HTTP/1.1" 200 68
      

        Gliffy Diagrams

          Attachments

            Issue Links

              Activity

                People

                • Assignee:
                  flavia.rainone Flavia Rainone
                  Reporter:
                  mmiura Masafumi Miura
                • Votes:
                  0 Vote for this issue
                  Watchers:
                  1 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved: