File tree Expand file tree Collapse file tree 1 file changed +3
-5
lines changed
core/src/main/scala/org/apache/spark/deploy/history Expand file tree Collapse file tree 1 file changed +3
-5
lines changed Original file line number Diff line number Diff line change @@ -103,11 +103,9 @@ class HistoryServer(
103103 // Note we don't use the UI retrieved from the cache; the cache loader above will register
104104 // the app's UI, and all we need to do is redirect the user to the same URI that was
105105 // requested, and the proper data should be served at that point.
106- if (req.getQueryString == null ) {
107- res.sendRedirect(res.encodeRedirectURL(req.getRequestURI()))
108- } else {
109- res.sendRedirect(res.encodeRedirectURL(req.getRequestURI + " ?" + req.getQueryString))
110- }
106+ // Also, make sure that the redirect url contains the query string present in the request.
107+ val requestURI = req.getRequestURI + Option (req.getQueryString).map(" ?" + _).getOrElse(" " )
108+ res.sendRedirect(res.encodeRedirectURL(requestURI))
111109 }
112110
113111 // SPARK-5983 ensure TRACE is not supported
You can’t perform that action at this time.
0 commit comments