Skip to content

Commit 021062a

Browse files
stanzhaisrowen
authored andcommitted
[SPARK-19622][WEBUI] Fix a http error in a paged table when using a Go button to search.
## What changes were proposed in this pull request? The search function of paged table is not available because of we don't skip the hash data of the reqeust path. ![](https://issues.apache.org/jira/secure/attachment/12852996/screenshot-1.png) ## How was this patch tested? Tested manually with my browser. Author: Stan Zhai <[email protected]> Closes #16953 from stanzhai/fix-webui-paged-table.
1 parent 9d2d220 commit 021062a

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

core/src/main/scala/org/apache/spark/ui/PagedTable.scala

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -175,13 +175,14 @@ private[ui] trait PagedTable[T] {
175175

176176
val hiddenFormFields = {
177177
if (goButtonFormPath.contains('?')) {
178-
val querystring = goButtonFormPath.split("\\?", 2)(1)
178+
val queryString = goButtonFormPath.split("\\?", 2)(1)
179+
val search = queryString.split("#")(0)
179180
Splitter
180181
.on('&')
181182
.trimResults()
182183
.omitEmptyStrings()
183184
.withKeyValueSeparator("=")
184-
.split(querystring)
185+
.split(search)
185186
.asScala
186187
.filterKeys(_ != pageSizeFormField)
187188
.filterKeys(_ != prevPageSizeFormField)

0 commit comments

Comments
 (0)