You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@kyuubi.apache.org by "zhaohehuhu (via GitHub)" <gi...@apache.org> on 2023/06/20 09:15:03 UTC

[GitHub] [kyuubi] zhaohehuhu commented on a diff in pull request #4983: [Improvement] [UI] Add query string to forward requests to Engine UI

zhaohehuhu commented on code in PR #4983:
URL: https://github.com/apache/kyuubi/pull/4983#discussion_r1234981395


##########
kyuubi-server/src/main/scala/org/apache/kyuubi/server/api/EngineUIProxyServlet.scala:
##########
@@ -30,14 +30,15 @@ private[api] class EngineUIProxyServlet extends ProxyServlet with Logging {
   override def rewriteTarget(request: HttpServletRequest): String = {
     val requestURL = request.getRequestURL
     val requestURI = request.getRequestURI
+    val queryString = getQueryString(request)
     var targetURL = "/no-ui-error"
     extractTargetAddress(requestURI).foreach { case (host, port) =>
       val targetURI = requestURI.stripPrefix(s"/engine-ui/$host:$port") match {
         // for some reason, the proxy can not handle redirect well, as a workaround,
         // we simulate the Spark UI redirection behavior and forcibly rewrite the
         // empty URI to the Spark Jobs page.
         case "" | "/" => "/jobs/"
-        case path => path
+        case path => path + queryString

Review Comment:
   OK. will add.



-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@kyuubi.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@kyuubi.apache.org
For additional commands, e-mail: notifications-help@kyuubi.apache.org