Repository: spark Updated Branches: refs/heads/master f590178d7 -> fdb382275
[SPARK-12186][WEB UI] Send the complete request URI including the query string when redirecting. Author: Rohit Agarwal <roh...@qubole.com> Closes #10180 from mindprince/SPARK-12186. Project: http://git-wip-us.apache.org/repos/asf/spark/repo Commit: http://git-wip-us.apache.org/repos/asf/spark/commit/fdb38227 Tree: http://git-wip-us.apache.org/repos/asf/spark/tree/fdb38227 Diff: http://git-wip-us.apache.org/repos/asf/spark/diff/fdb38227 Branch: refs/heads/master Commit: fdb38227564c1af40cbfb97df420b23eb04c002b Parents: f590178 Author: Rohit Agarwal <roh...@qubole.com> Authored: Wed Dec 16 19:04:33 2015 -0800 Committer: Andrew Or <and...@databricks.com> Committed: Wed Dec 16 19:04:33 2015 -0800 ---------------------------------------------------------------------- .../scala/org/apache/spark/deploy/history/HistoryServer.scala | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/spark/blob/fdb38227/core/src/main/scala/org/apache/spark/deploy/history/HistoryServer.scala ---------------------------------------------------------------------- diff --git a/core/src/main/scala/org/apache/spark/deploy/history/HistoryServer.scala b/core/src/main/scala/org/apache/spark/deploy/history/HistoryServer.scala index d4f327c..f31fef0 100644 --- a/core/src/main/scala/org/apache/spark/deploy/history/HistoryServer.scala +++ b/core/src/main/scala/org/apache/spark/deploy/history/HistoryServer.scala @@ -103,7 +103,9 @@ class HistoryServer( // Note we don't use the UI retrieved from the cache; the cache loader above will register // the app's UI, and all we need to do is redirect the user to the same URI that was // requested, and the proper data should be served at that point. - res.sendRedirect(res.encodeRedirectURL(req.getRequestURI())) + // Also, make sure that the redirect url contains the query string present in the request. + val requestURI = req.getRequestURI + Option(req.getQueryString).map("?" + _).getOrElse("") + res.sendRedirect(res.encodeRedirectURL(requestURI)) } // SPARK-5983 ensure TRACE is not supported --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@spark.apache.org For additional commands, e-mail: commits-h...@spark.apache.org